A TARDIS with a functioning chameleon circuit can appear as almost anything, if its owner desires. The owner can programme the circuit to make it assume a specific shape or else the TARDIS itself can decide what form to take. The chameleon circuit should make the TARDIS fit in to the natural environment of a specific destination. The perception filter also helps a TARDIS to disguise itself. (TW: Everything Changes)
The Doctor once referred to chameleon circuit of his TARDIS as a "cloaking device". The fact that he hesitated slightly before using the term "cloaking device" suggests that he was trying to think of an alternative to "chameleon circuit". (DW: Doctor Who)
The chameleon circuit of the Doctor's TARDIS, however, has rarely worked properly since the First Doctor made a sudden departure from Totter's Lane, Shoreditch, 1963, and has usually remained in the shape of a London police box. (DW: An Unearthly Child)
The Doctor hoped to repair it in Logopolis by using Block Transfer Computations when the Master interfered with the Logopolitans' calculations. (DW: Logopolis) He succeeded in repairing it for a brief period when he returned to Totter's Lane in 1986, but after it began to transform into shapes that still refused to blend into their surroundings - and on some occasions even made it hard to figure out how he was meant to enter his ship in the first place - he reverted it back to its usual police box form. (DW: Attack of the Cybermen)
During his seventh incarnation, the Doctor briefly enabled his ship to work again (NA: Conundrum), but reset it back to a police box after Mortimus hacked into the circuit and nearly gave away its location by turning it into something else. (NA: No Future)
After Donna Noble reported her encounter with Rose Tyler to the Doctor, he began noticing that the words "Bad Wolf" had begun to appear everywhere, including replacing the traditional police box lettering on his TARDIS. These words were also visible from the interior of the TARDIS over the doorway. It is likely the chameleon circuit was somehow activated in order to make this change. (DW: Turn Left)
Later, when Donna briefly had a Time Lord consciousness, she began to tell the Doctor how to repair the circuit, but her brain began to overload before she could complete the instructions while stating "Binary" in a recurative fashion. (DW: Journey's End)
However, the Doctor in recent incarnations has shown no particular interest in repairing the circuit, with the ninth incarnation more or less telling Rose that he likes its appearance. (DW: Boom Town) When the Master took possession of the TARDIS for an extended period of time, he also declined to fix the chameleon circuit (although the fact that he was incapable of travelling anywhere but to two locations may have meant that he simply saw no point in it). (DW: The Sound of Drums / Last of the Time Lords)
The upcoming Series 5 sees a total redesign of the TARDIS interior, along with noticeable changes to the exterior, though the general shape remains the same, the colouring and size is slightly different and the St. John's Ambulance logo, that appeared on the police box during the First Doctor era, is to be restored. Despite the show's production making minor aesthetic changes to the TARDIS exterior throughout it's run without ever needing to explain it, the changes are set to be explained in this series. The previous episode saw an explosive regeneration that clearly destroys much of the TARDIS interior and exterior, and leaked script excerpts for the first episode reveals that, having repaired the damage to the TARDIS interior, The Doctor fixes the chameleon circuit and flies the TARDIS to Totter's Lane in 1963, the setting of the first episode where the circuit was first seen to get stuck, and break it himself, but the disguise is imperfect leading to a slightly different appearance than previously.
The Monk's TARDIS appeared as a sarcophagus in an English church of 1066, (DW: The Time Meddler), a large stone on Tigus, and a stone block in Ancient Egypt. The Doctor caused it to appear as an Ionic column, a stage coach, a tree, an igloo, a rocket, and a bi-plane before impishly setting it as a police box to distract the Daleks. (DW: The Daleks' Master Plan)
The real world reason for the malfunction is thought to be of a far more practical nature: the Chameleon Circuit was intended to allow the TARDIS to blend with its surroundings during the 'historical' episodes which would require an expensive redress of the TARDIS prop for every episode. Others have suggested that the shape was initially selected to provide something that the present audiences would instantly recognise.
The Trock band "Chameleon Circuit" are named after this TARDIS component.