Redirect htaccess all urls to new domain

This sentence redirects all pages from an old domain (olddomain.com) to the root of the new domain (newdomain.com)

Options +FollowSymLinks
RewriteEngine On
RewriteBase /
RewriteCond %{HTTP_HOST} ^OLDDOMAIN\.com$ [NC]
RewriteRule ^(.*)$ http://NEWDOMAIN.com [R=301,L]