During the address in Chicago, Mr Obama warned democracy is threatened whenever people take it for granted.
He mentioned three main threats to America's democracy - economic inequality, racial divisions and the tendency for people to retreat into their own bubbles.
The farewell speech included a recap of what Barack Obama regards as some of the major achievements of the past eight years.
These include dealing with the Global Financial Crisis; striking a deal with Iran over its nuclear program; killing Osama Bin Laden, getting his healthcare reforms through and achieving a social reform Australia is yet to achieve.
"If I told you that we would win marriage equality and secure the right to health insurance for another 20 million of our fellow citizens, if I told you all that, you might have said our sights were set a little too high."
And on his signature healthcare reforms known as Obamacare, he reiterated a message to those in the Republican party who want to replace it.
"If anyone can put together a plan that is demonstrably better than the improvements we made to our healthcare system, that covers as many people at less cost, I will publicly support it."
Barack Obama says after his eight years in office unemployment is near a 10 year low and poverty rates are down.
He claimed race relations had improved under his watch, but said America could do better.
"If every economic issue is framed as a struggle between a hard working white middle class and an underserving minority then workers of all shades are going to be left fighting for scraps while the wealthy withdraw further into their private enclaves. If we're unwilling to invest in the children of immigrants just because they don't look like us, we will diminish the prospects of our own children because those brown kids will represent a larger and larger share of America's workforce."
The outgoing president appealed to Americans from all backgrounds to try to consider issues from another's viewpoint.
"For blacks and other minority groups that means tying our own very real struggle for justice to the challenges that a lot of people in this country face. Not only the refugee or the immigrant or the rural poor or the transgender American but also the middle aged white guy who, from the outside may seem like he has got advantages but has seen his world upended by economic and cultural and technological change. We have to pay attention and listen."
When calling for Americans to defend democracy, he encouraged them to be proactive and not just at the ballot box every four years.
"It needs you, not just when there's an election, not just when your own narrow interest is at stake but over the full span of a lifetime. If you're tired with argiung with strangers over the internet, try talking with one of them in real life.
Towards the end of his speech Barack Obama wiped away tears.
He ended with an appeal to his fellow citizens to believe in their own ability to bring about change, just like those who have gone before them.
"I am asking you to hold fast to that faith written into our founding documents, that idea whispered by slaves and abolitionists*, that spirit sung by immigrants and homesteaders and those who marched for justice, that creed reaffirmed by those who planted flags from foreign battle fields to the surface of the moon. A creed at the core of every American whose story is not yet written. Yes we can. (Applause) Yes we did, yes we did, thank you, God bless you, may God continue to bless the United States of America."