All of these are words used to express contrast. While but and though are conjunctions, in spite of and despite are prepositions.
Read the following sentences.
He was ill. Still he went to work.
The meanings of these two sentences can be expressed in a single sentence in the following ways.
He was ill but he went to work.
Though he was ill, he went to work.
In spite of being ill, he went to work.
In spite of his illness, he went to work.
Despite his illness, he went to work.
Let's practice!