Change Domain from test to Live

Hello,

I set up a domain for a client. Now the client is happy with the website and wants to go live. Is it possible to simply change the domain, or do I need to create a new website for the live domain?

test website is domain: test.example.com
live website domain would be: example.com

It is a WordPress website.

Thanks
Fafa24

Easiest way is use migration plugin.