This is a very controversial topic because the causes of the 2008 crisis are not completely agreed upon. The task force set to study this by the US government recently released three separate reports because the members could not agree on the causes of the crisis.
It is generally believed by historians that a lack of regulation of banks, in particular, helped cause the crash of 1929. Banks were able to take their depositors' money and use it to invest in the stock market. This helped to overinflate stock prices and it helped to make the banks extremely weak when the stock market crashed.
Some people who have studied the 2008 crash believe that it came about because of insufficient regulation of the mortgage industry and, perhaps, the financial industry. They believe, for example, that better regulation of the mortgage industry would have prevented the bad loans that later became "toxic." However, this is a controversial position that is not accepted by all.
To some people, then, both the 1929 and 2008 crises were caused in part by a lack of government regulation of one part of the financial industry or another.