Chosen Solution

The day before the MacBook Air died it notified me the battery needed replacing and laptop would immediately shut out if disconnected from mains power as the battery wasn’t holding any charge. The next day, having been left connected to mains power overnight the laptop won’t turn on and the MagSafe 2 light is off. I tried a different connector and it still didn’t work. I have now replaced the battery but this didn’t work. I have checked circuit board for corrosion and can see none, wiped off some dirt with alcohol, but still no change. No idea what to do now, I’d be extremely greatful for any suggestions! This is what the charging port looks like:

You’ll need to walk though the pathway from the charger to the system. Is the MagSafe charger cable in good shape? Make sure it doesn’t look like these

How does the pins in the connector look like?

Next inspection your systems MagSafe port, is it clean or fill with junk?

Is one of the pins damaged or burn’t?

Let us know what you find Update (09/26/2021) So it does sound like you’ll need a new charger for starters. Here’s a like to Apples website to get the needed charger: Apple 45W MagSafe Power Adapter for MacBook Air You may also need a new MacBook Air 13" (Mid 2013-2017) I/O Board Here’s the guide to get to it MacBook Air 13" Early 2017 I/O Board Replacement. I do fear you may have a deeper issue in the main logic board as well.