You have a blown head gasket.
Check the thermostat or the radiator. The thermostat could be sticking or the radiator could be plugged.
Bad thermostat, cap and radiator is a common cause.
Bad radiator, gaskets, water pump, thermostat
You may need to replace the radiator thermostat and gasket.
It could be the radiator is clogged. The thermostat could be bad (prevents the coolant from circulating from radiator to engine block)
Fixer pluged radiator or caused thermostat to stick shut.
Check the fan thermostat.
Check to see if the thermostat got put in backwards. Make absolutely sure it's completely full of coolant.
One reasons a Subaru Forester may overheat is because the radiator may need replaced. Another reason could be the thermostat.
Low coolant, stuck thermostat, failed waterpump, plugged radiator, inoperative radiator fans, etc.
Low coolant, plugged radiator, inoperative fan, stuck thermostat.
Bad thermostat, plugged radiator, blown head gasket in order of expense.