Futon mattresses these days come in a dizzying array of styles. How they wear depends on what is inside, how thick they are and how they are used. Daily use is harder on them than occasional use. Futon mattress materials include cotton, foam, wool, polyester, foam latex as well as an innerspring surrounded with cotton or foam. Mattresses with foam inside, which come in standard and deluxe versions, take longer to compress and usually last several years with occasional use. Those made with cotton do get compressed and hard sooner than others. If your mattress has become compressed and feels lumpy or hard when you sit or lie on it, it is time to replace it. Get a new one that is as thick as possible, with foam inside for both comfort and longevity.
Frames come in wood and metal and there are hundreds of designs to choose from. Both are made to fold up and down, with hinges or a slide mechanism on the sides and/or back. How long they last depends on how often they are opened and closed for sleeping. Most wood frames these days are made of rubber wood, usually from Indonesia. It is very durable, glues together well and is thus able to handle the stress of converting the frame from sofa to bed and back. Good-quality metal frames are similarly durable. Check the frame from time to time to make sure no part wiggles, and that the bolts are tight. Manufacturers do sell screws, bolts and hinges for frame repair. Over time, however, you may find that your frame breaks in a way which cannot be repaired; you need to replace it then. Alternately you may want to change the style of the frame, and buy a new frame since even good quality frames are not expensive.
If you buy a new futon mattress or frame, there are several ways to ensure their durability. Mattresses should be turned every couple of weeks to minimize the compression. They should also be aired and vacuumed from time to time. Use a good cover which can be removed and laundered or dry cleaned. It is worth spending a bit more on a quality frame. Hardwood lasts longer and the more reinforcement the frame has, the better it will withstand constant use.