Read James 1:26-27 to find out:

“If anyone considers himself religious and yet does not keep a tight rein on his tongue, he deceives himself and his religion is worthless.  Religion that God our Father accepts as pure and faultless is this: to look after orphans and widows in their distress and to keep oneself from being polluted by the world.”

It is very interesting that James use the word “religion”, the greek word “Threskeia”.  It is used only 4 times in the New Testament, twice here, once in Acts describing Judaism, and once in Colossians chapter two, describing the false worship of angels.
James uses it here in a tongue in cheek way.  James knows that it is human nature to desire to be viewed as a religious person.  Most people who are considered religious are often known as this because of the outward ceremonies they participate in, which includes the physical motions of posturing, bowing, standing, kneeling, and repeating common phases.   The external religious activities are appealing to our flesh to make us feel like we are connected to God, and that we are part of something bigger than ourselves. Whether that is really true or not is a completely different matter.
James is pitting religious ceremonial externalities against the types of outward things that God approves of: 

1.  controlling the tongue
2.  looking after orphans and widows
3.  not participating in the sinful things of the world

While this is not an all inclusive list, it does give us a major clue of how God wants us to live our short lives – loving Him and loving our neighbors.