London, England (CNN) -- The roof is cracking at the place where the British cracked the Enigma code in World War II. So are the roads and fences.
Now, the neglected mansion at Bletchley Park, where Alan Turing and others were able to decipher coded German military messages and help speed the end of the war, is getting a much-needed dose of funding and recognition.
The British government announced Thursday it is giving £250,000 ($372,000) to help carry out badly-needed repairs at the run-down site near Milton Keynes, just north of London, which now houses a museum to teach visitors about its place in history.
"The work carried out at Bletchley Park had a huge impact on the course of the war, and the museum does a brilliant job in bringing this alive for people of all ages," said Culture Secretary Ben Bradshaw, whose department is allocating the money.
"But having doubled its visitor numbers over the last three years, it urgently needs funds to keep it in good condition."
The money will be used to do basic repairs on roads, parking lots, roofs, drains, and fencing, said Simon Greenish, the chief executive and director of the Bletchley Park Trust.
"At the moment, they're pretty dreadful," Greenish told CNN. "The roads have not had any significant attention for many years. The car parks have reached a point where they failed, and the fencing is not providing any security at all. So all of this work is very timely."
Bletchley is where Turing, a Cambridge University-educated mathematician, invented the Bombe, a code-breaking machine that deciphered messages encoded by German Enigma machines during the war. Turing's work is considered the basis of modern computing.
Bletchley Park announced in October that it is in line to receive £4.1 million ($6.1 million) in lottery funding, subject to the trust raising another £1 million ($1.5 million) in matching funding. Thursday's funding will speed the repairs.
"This enormously appreciated funding will not only enable vital repair and maintenance of this World War II site for the benefit of our rapidly growing number of visitors, but it also represents endorsement by the Department for Culture, Media and Sport that Bletchley Park is a place of national importance which deserves government support," Greenish said in a statement.
The Enigma code was the backbone of German military and intelligence communications. It had originally been developed in 1918 for use in banking, but the German military saw its potential for military use and adapted it.
The machine that produced the code was a system of rotors, keyboards, and electrical wires resembling a typewriter, according to the National Archives. The machine was portable and ideally suited for use in combat, and was quickly adopted by all branches of the German armed forces, the National Archives said.
The Germans thought it was unbreakable, but the code had its flaws. One fundamental flaw was that no letter could ever be encrypted as itself. Another was the errors in messages sent by tired, lazy, or stressed German operators, and yet another was the German habit of using standard phrases at the start of each message, allowing cryptanalysts to establish educated guesses.
Turing and fellow Cambridge mathematician Gordon Welchman worked at Bletchley to improve a Polish machine that had been built before the war to crack earlier versions of Enigma. The pair's new Bombe was perfected in 1940 and they began deciphering Luftwaffe communications.
Once set in motion, the Bombe would search through all possible Enigma rotor variations until the right combination was found. The complex Enigma methods used in German naval communications were cracked in 1941, then again in 1943, after the navy had introduced extra components to the system.
Intercept stations dotted around Britain and in several countries overseas listened to the Germans' messages and sent them to Bletchley Park, where codebreakers working in numbered huts would decode the messages and turn them into intelligence reports.
Bletchley was also where post office engineer Tommy Flowers built an electronic machine to decipher the Lorenz code, a complex encryption system used by Hitler and the German High Command.
Over nine months in 1943, Flowers and a few dozen technicians built the first large, high-speed, electronic valve programmable logic calculator. It measured 5 meters long, 3 meters deep and 2.5 meters high, and was assembled from telephone exchange parts.
The machine could process 5,000 letters per second and enabled the Allies to eavesdrop on the German High Command before D-Day. The deciphered intelligence provided critical information on troop positions in Normandy before the Allied invasion began on June 6, 1944, according to Bletchley Park.