To change the user agent, first, you will have to enable the Developer mode. To do this, open Safari, then go to Preferences. Click the Advanced tab and then tick the option that says how Develop menu in menu bar. Locate the Develop menu available in the menu bar, then go to User Agent. Choose the strings from the list or use Other and specify the parameters for the new user agent. Your browsing experience might change a little based on the options selected in the User Agent menu and options.