Think of your ISA like a hotel. Currently the money is in one room, but its reservation is nearly finished.
While the money is in one of the hotel rooms, any interest or returns it makes is tax free.
At that point you can take it out of the hotel entirely or put into another room in the hotel.
There’s no tax if you take it out of the hotel (even if you just take the interest out of the hotel), but if you save/invest it somewhere else once you’ve taken it out of the hotel you will pay tax on the interest and returns it makes (subject to your £500 tax free allowance).
You don’t need to take it out of the hotel at when the reservations up. Most banks will move it to another hotel room for you, but one that pays a low interest rate. You can leave it there while you decide where to put it long term. You can find a better interest rate and move it there for a short amount of time (provided it’s an “easy access” ‘room’) while you decide where to put it long term.
At no point is there ever any tax on taking the money out of the hotel. The tax only comes if you make interest or a return on the money you have taken out.
There’s limits on how much you can “check in” to the hotel every year, but no limit on how much can be in the hotel in total.
If you take it out, you will need to make sure you have enough allowance to be able to put it back into the hotel if that’s where you want it to be in future.
Does that help?