When actively being used when connected to an available wi-fi network, the connection to the wi-fi network should remain.
When the iPhone's screen is off or asleep and the iPhone has not be used for 5 minutes or so, the wi-fi connection will be dropped. When waking the iPhone up, it should quickly re-connect to the network - in a second or two.
Thanks for the info. I just played around with it for a few minutes and it did stay connected when I was using an app or safari. It was just when I was browsing the settings or looking at photos that it was switching. Does switching back and forth put a big strain on the battery? Because I've been having issues with battey life as well.
I have never noticed my wi-fi connection being dropped when checking settings or looking at photos, etc. Not saying it hasn't for certain but if so, I haven't noticed it after using an iPhone for over 4 years now.
The disconnect from wi-fi when not being used is to save battery. The same does not occur when the iPhone remains connected to a power source.