I think my SD card may be buggy, so I'd like to reformat it.

So I don't lose whatever important stuff is located on it, I obviously want to back it up before formatting.

I have Android FIle Transfer installed on my Mac. Am I correct that to do the backup, I just drag all the contents of the SD card into a new folder on my Mac.

Then I reformat the SD card using the procedure on the phone.

Then I restore the data by dragging the files back onto the SD card (via Android File Transfer)?

Apologies for the incredibly basic question, but just want to make sure I've got it correct before proceeding.