Most panels last somewhere around 25 years. Sunpower itself also has a warranty of 25 years on a panel, and should not decline to less than 87%. Obviously, over time, any panels efficiency will slowly deteriorate. You can still use an older panel; its energy generation will just be lower. Most testing shows that panels will actually still be operable and will still produce a nominal amount of energy many years after the 25 year checkpoint.
There isn’t much you can do that already is done. Panels have a 25 year warranty already with them because they are designed to last for a very long time and don’t simply fail a year in. Most of what people can do for their solar panels is minimal but still helps. Make sure they to keep them clean and healthy. Try to not maintain scratches, dirt or dust on the surface of the panels. Most importantly and obviously, don’t let a stray branch fly and break them. This can help your panels at a higher efficiency.
While there isn’t a massive problem of solar waste as of now, in the foreseeable future, this may become a problem. Many panels have materials like glass and aluminum that can be salvaged and reused, so many companies have been looking at recycling panels. Because many panels must be collected, there must be an initiative to go to individual houses and transport dead panels to recycling centers. This together with the process of actually separating all the materials at the center could sum to a high cost. Despite this, in the future there will be increased demand for this. More people will have solar panels, and there will be more incentive for greener ways to dispose of panels. Recycling them only seems a fitting end to the life of a source of green energy.