There are a variety of things that can cause a brake pedal to feel spongy, such as a defective master cylinder, a twisted hard line or incorrectly adjusted rear calipers. The only way to determine the cause is by taking a look at the braking system or taking the vehicle to a qualified mechanic.
There is a proven way to test the brakes, possibly avoiding a costly trip to the shop. Under the car, at the center of the rear axle, is a rubber hose called a rear flex hose. Clamp that hose so no fluid is able to pass through. Once it's clamped, start the car and depress the brake pedal.
If the brakes are more solid with this hose clamped, chances are the problem lies behind this rear flex hose. This is common with vehicles that have drum brakes in the rear. To remedy the situation, the brakes will need to be bled thoroughly, removing all the air from the lines. If the vehicle has a parking brake, this should be engaged during the process.
If clamping the rear flex hose doesn't add substance to the brakes, the problem lies in front of the hose. Drivers can try adjusting the front caliper bleeders to where they are not pointing up. This causes air in the system, resulting in a spongy feel.
Unreliable brakes puts driver and passengers at risk and when there is a doubt about brake problems, a qualified mechanic should be consulted.