In a recent series of posts on my Instagram feed entitled 'Learning The Fretboard' I shared a number of essential concepts and shapes that will radically accelerate your learning of notes on the guitar fretboard.
My final post in the series was the video below which details what I think is the best exercise for learning the fretboard. It certainly worked for me!.
This is an exercise taken from Joe Satriani's book 'Guitar Secrets' (a great compilation of articles written by the guitar legend).
What you need is a fretboard diagram of all the notes and a metronome. Taking each of the 12 chromatic notes in turn, your goal is to play that given note on all six strings, from string 6 to string 1 and back. Each note will appear on every string in the first 12 frets.
But, you must pick the notes in time with the metronome click. Work at a slow tempe (50-60 BPM) and with the fretboard diagram in front of you if you need. Take 3 or 4 notes every practice session (I like to work around the circle of fourths - A-D-C-F-Bb...)
Keep working at increasing the tempo until you feel confident that you know where the notes are.