How to Remember Guitar String Names
A guitar's six open strings in standard tuning are six specific notes, and their order only needs to be learned once to never confuse 'which string is which' again. The easiest way to do that isn't rote memorization - it's a mnemonic phrase.
From the thickest string to the thinnest: E A D G B E
The count always starts from the thickest (and lowest-sounding) string, physically closest to the ceiling when holding the guitar in playing position, down to the thinnest: E, A, D, G, B, E. The last, sixth string is E again, just two octaves above the first.
The classic mnemonic: Eddie Ate Dynamite
The best-known mnemonic for E A D G B E is 'Eddie Ate Dynamite, Good Bye Eddie' - the first letter of each word gives the correct note order. It works no matter what language you think about music in - plenty of guitarists use it purely because it sticks in memory well.
You can build your own phrase
The exact phrase doesn't matter - what matters is the principle: pick any memorable sentence where each word's first letter spells out E-A-D-G-B-E, and it works exactly as well as the classic one. A phrase you made up yourself is often easier to recall than someone else's, precisely because you built it.
String numbering runs the opposite way
One detail that trips up a lot of beginners: strings are numbered from thinnest to thickest, meaning the 1st string is the thinnest (highest) E, and the 6th is the thickest (lowest) E. The numbering direction is the opposite of the direction you usually name the tuning's notes in - that's not a mistake, just a separate convention worth memorizing on its own.
How to make it stick in practice
The easiest way to lock in the string names is to say them out loud while tuning the guitar (see the article on tuning) - every time you adjust a string, say its name. After a few days of regular tuning, each string's name comes to mind on its own, with no conscious runthrough of the mnemonic needed.
Try it in practice
Open the tuner