Skip to content

JavaScript toLocaleUpperCase() | String method

  • by

JavaScript toLocaleUpperCase() string method is used to convert the string to an uppercase letter on the basis of the host’s current locale. The locale is based on the language settings of the browser.


This method does not change the original string and returns the same result as toUpperCase() method.

JavaScript toLocaleUpperCase()

Simple example code.

<!DOCTYPE html>
    const city = 'istanbul';




JavaScript toLocaleUpperCase String method

More examples

'alphabet'.toLocaleUpperCase(); // 'ALPHABET'

'Gesäß'.toLocaleUpperCase(); // 'GESÄSS'

'i\u0307'.toLocaleUpperCase('lt-LT'); // 'I'

let locales = ['lt', 'LT', 'lt-LT', 'lt-u-co-phonebk', 'lt-x-lietuva'];
'i\u0307'.toLocaleUpperCase(locales); // 'I'

Do comment if you have any doubts or suggestions on this Js string method tutorial.

Note: The All JS Examples codes are tested on the Firefox browser and the Chrome browser.

OS: Windows 10

Code: HTML 5 Version

Leave a Reply

Your email address will not be published. Required fields are marked *