1. Draw a cartoon related to the sentence.

2. Draw a cartoon relating to the sentence.

3. Draw a cartoon and write down a sentence related to it below.

4. Draw a cartoon and write dwon a sentence related to it below.

-------------------------
Are the sentences above grammatical?
Do we have to use 'related' or 'relating'?

3 answers

They are all OK. The first and third are the best. The fourth has a spelling error (or typo).

The sentence related to the cartoon or photo or picture is called a caption. You could write this:

Draw a cartoon and a caption below it.
4. Draw a cartoon and write down a sentence relating to it below.

Thank you. #4 should be like this.

Do you mean we can use both 'related' and 'relating'?
Yes, you can. There's not much difference between them; mostly the difference is in the participial form (present or past), not in meaning.