How do I come to the spiritual realisation that the world is not real?

What you are describing is dissociation and it is a psychological distortion.

Convincing yourself that the world is not real is neither helpful nor is it spiritually recommended.

The world is real. It’s just not as real as you think. There is a subtle but profound difference in this statement.

When used as a spiritual teaching, such “medicine” will have the effect of dismantling your conditioned beliefs relating to the nature of your existence.

However, it’s not advisable to allow such teaching to spread its seed unless it has been specifically prescribed for you by a spiritual teacher/guide or psychotherapist.

Taking medicine meant for someone else is never a good idea.

Exercising discernment about what is allowed to take root within your psyche will bring you more into alignment with that which you ultimately seek.