Ikhlas (Sincerity) is worshipping for the noble countenance of Allah. It is to do acts of worship for the sake of Allah. It is everything we are and do solely for Allah, The Most High. Ikhlas is to close the gap between what we say and what we do. It is to talk the talk and walk the walk. It is to intend in our hearts to please Allah, seeking His love and reward. It is to love and obey Allah because He is our master and we are His servants. We worship Allah because He is Allah, and with that comes His pleasure and paradise. Ikhlas is a virtue of the heart that causes us to purely and only worship Allah, turning away from everything else. It is to care only about how Allah sees you and not what people think of you.
The opposite of ikhlas is riya (ostentation). Riya is worshipping for other than Allah. It is to do acts of worship for the sake of people. It is showing off in religious works so that one can be seen and heard. Riya is a minor shirk (polytheism), not a major shirk, because it is insincerely doing what is meant for Allah for the sake of people. It is a major sin and vice of the heart. It is to care what people think of you over how Allah sees you.
It is important to know the definitions of ikhlas and riya because things are distinguished by their opposites. If we understand what ikhlas is, then we know what riya is and what ikhlas is not. First, one would work to remove the vice of riya from the heart. Then, one would work to adorn the virtue of ikhlas in the heart. This is part of the process of tazkiyah (purification of the heart). Mainly, we need to renew and rectify our intention to do everything we do, inwardly and outwardly, seen and unseen, big and small, sincerely and solely for the sake of Allah and not for nothing or no one else.
May Allah give us true ikhlas and remove riya from us in goodness, gentleness, and well-being. Amin.