Hydrogen peroxide should last at least a year after being opened, as long as dirt does not get in it. If dirt gets in the bottle, the shelf life depends on the nature of the dirt. The hydrogen peroxide could last another year, or just a few days.
To test whether it is still effective, you can pour it in to the sink and see if it fizzes and bubbles. If it does, it's still good.
The product does not need to be replaced until it is used up.