There are actually two questions here, I think :
1. Why did France invade Algeria in 1830?
For a long time, the historical record said that it all started because of a "coup d'éventail" given in 1827 by the dey of Algier to the french envoy, Deval. The reason for this : Deval had negotiated with a wealthy Algerian family, who sent a huge quantity of wheat to France during the revolutionary decade. Thirty years later, the wheat had still not been paid. However, the french took offense to this "coup d'éventail" and swore to avenge it. Hence the invasion.
Nowadays, historians also point to the fact that Charles X's monarchy needed the glory of a military victory to reinforce its power in France. They were also looking to Algeria as a potential market in which to sell early industrial goods.
2. Why did France colonize Algeria?
During the 1830s and 1840s, the situation in Algeria was not settled, and there were debates among the french to know if they should stay in the country. The country was not invaded all at once ; indeed, until the end of the 1840s, it was more like small parcels of occupied territory. Some people objected either to the cost of the occupation (financial and human, for it was a terribly brutal and bloody invasion) ; some also criticized the idea of a colony in and of itself, which felt reminiscent of the inequalities of the Ancient Régime. However, the financial and political interests of those in favor of the colonization won the "debate".
Sources :
Benjamin Stora, Histoire de l'Algérie coloniale, Paris, La découverte, 2004
Hélène Blais, "Pourquoi la France a-t-elle conquis l'Algérie", in Bouchène & Peyroulou, Histoire de l'Algérie coloniale, La découverte, 2012