How to change the domain name of a website, not loosing Google rankings?

If you decided to change the domain name of your website, don’t forget that there are some rules how to do it. Remember that you mustn’t change the URL structure, CMS, design or content in this process.