Iphone app that controls lights?

I heard there's an app where you can control the lights on your iphone if you forgot to turn them off at home. However, I heard some apps you actually need to pay for the service if its Lutron or whatnot. Some apps are free but you have to order some other service thingy. Is there a free app that just requires Wi-Fi and no electronic charge all around the house?

It is not so much an app you need, but hardware that you can control things from a network or the Internet.

Now, you need some sort of locator service so that your app can find the devices in your house.
The way most home Internet connections work is that one can't directly connect to things from the outside world. It is a matter of finding devices that offer the service free.

Belkin might offer that with their remote outlet.