The time-honored way is to play along with CDs. Okay, really the time honored way was to play along with records. Then it was tapes. Now CDs. Load up your favorite music, learn it by ear, and play it. Over and over. Until your fingers are raw and it's 5 in the morning and the birds are waking up.
It's all too easy today to go to a tab site and pick up somebody's interpretation of how to play the song, but it's far better for your ear and your technique to figure the song out for yourself, note for note. This is how all the greats did it. And even us not-so-greats.
Jamming with other musicians helps a lot too, as long as they are competent. Try to play with people who are above your level so they force you to improve, rather than less experienced players who will slow you down.