The winger left Crystal Palace this summer.
The 30-year-old was available on a free transfer after his deal at Crystal Palace expired at the end of last season.
The move will see Townsend link up once again with Rafael Benitez the new Everton manager, after previously playing under the Spaniard at Newcastle.
Townsend told Everton TV: “I think everyone knows what Everton is. It’s a massive football club, it’s very ambitious, a club which has been trying to get back to where it belongs into Europe and beyond.
“I’ll be doing all I can to help the club do that. As the old cliche goes, it was a no-brainer.
“Rafa is very experienced. He does a lot of work on the tactical side on the training pitch, he leaves no stone unturned.
“But, more importantly, he’s a great man, a great man-manager, and he’s always talking to you. I’m sure he will be very successful here.”
Townsend, who has 13 England caps, made his name at Tottenham, where he came through the youth ranks.
He moved to Newcastle in 2016 but left for Palace after their relegation from the Premier League later that year. He spent five seasons at Selhurst Park.
Townsend tweeted: “After 5 amazing years and countless memories, it’s time to say my goodbyes to everyone at Crystal Palace.
“I’d like to say particular thank yous to the chairman for bringing me to Selhurst and giving me the opportunity to wear the red and blue, to Sam (Allardyce) and Roy (Hodgson) for their belief in me, and to my team-mates for the special moments we enjoyed together on the pitch.
“To the Palace fans. The beating heart of the club. To each and every one of you… Thank you. Thank you for all of your support, it’s that support which makes the club and Selhurst Park so special.
“It’s a shame we didn’t get to say goodbye properly, but we’ll be seeing each other soon enough and I’m already looking forward to returning to Selhurst when we meet again. Until next time, there’s a star-man playing on the right.”