Diagnosis
Low power output. The usual suspects are a failing magnetron (the tube that generates the microwaves) or a faulty high-voltage capacitor that isn't providing the proper voltage to it.
How to Fix It
Do a simple water test. Put exactly 1 cup of cold tap water in a glass measuring cup. Heat on high for 2 minutes. It should be very hot, nearly boiling. If it's just warm, power is low. Before condemning the magnetron, check the internal waveguide cover (that mica plate on the side wall) for heavy grime or damage, as that can absorb energy. Clean it as described in the other answer.
If That Didn't Work
The high-voltage capacitor can lose its ability to hold a charge, reducing power to the magnetron. Testing it requires a multimeter and discharging it safely. A weak magnetron is the other possibility. Diagnosing which requires component-level testing or substitution by someone familiar with microwave repair.
Heads Up
A microwave with a significantly weakened magnetron can sometimes still run but may draw excessive current, potentially overheating wiring or stressing other components. It's not just an inconvenience; it can be a safety issue.