Java Character toLowerCase() Method

Beginner
5 min read
Updated: Nov 2026
3 examples
java.lang.Character

Definition

In Java, Character.toLowerCase(ch) returns the lowercase form of a character: 'A' becomes 'a', Greek capital alpha becomes small alpha. Characters with no lowercase form, such as digits, punctuation, and letters that are already lowercase, come back unchanged.

It uses the simple, one-to-one mapping from the Unicode data, and it never looks at the locale. For whole words, or for language rules such as Turkish dotted and dotless i, use String.toLowerCase(Locale).

A static method of java.lang.Character (Java 1.0+): call it on the class, as in Character.toLowerCase(...); you do not need a Character object. No import is needed, because java.lang is always available. The int codePoint overload was added in Java 5.

Unicode version.

The answer comes from the Unicode Character Database built into your JDK, and each Java release follows a specific Unicode version (Java 8, for example, uses Unicode 6.2). The characters used on this page have had the same properties for many Unicode versions, so the examples print the same result on any current JDK.

Syntax

The char overload returns a char; the int overload returns an int code point.

Java
char a = Character.toLowerCase('A');      // 'a'
char b = Character.toLowerCase('a');      // 'a', already lowercase
char c = Character.toLowerCase('7');      // '7', no case
int d = Character.toLowerCase(0x0391);    // 0x03B1 (945), Greek small alpha
CallWhat it does
Character.toLowerCase(c)Lowercase one char.
Character.toLowerCase(a) == Character.toLowerCase(b)Compare two characters ignoring case (for most scripts).
Character.toLowerCase(s.codePointAt(i))Lowercase a full code point.

Overloads: char toLowerCase(char ch) and int toLowerCase(int codePoint). Keep the result type in mind: printing the int version shows a number, not a letter.

Library declarations
Java
// java.lang.Character
public static char toLowerCase(char ch)
public static int toLowerCase(int codePoint)   // since Java 5

Parameters

ParameterDescription
ch (char)The character to convert.
codePoint (int)The code point to convert.

Return Value

Return ValueDescription
char / intThe lowercase equivalent, or the argument itself if it has none.

Compare with Similar Methods

Other ways to change or test case:

MethodHow it differs
String.toLowerCase(Locale)Converts a whole string with the rules of a language.
toUpperCase(ch)The uppercase direction.
isLowerCase(ch)Tests instead of converting.

Java Examples

Example 1 — Lowercase Text One Character at a Time

Build a lowercase copy of a mixed-case string with a StringBuilder.

Java
public class CharacterToLowerCaseText {
    public static void main(String[] args) {
        String text = "HeLLo, JAVA 8!";
        StringBuilder lower = new StringBuilder(text.length());
        for (int i = 0; i < text.length(); i++) {
            lower.append(Character.toLowerCase(text.charAt(i)));
        }
        System.out.println(lower);
    }
}

How It Works

  1. A builder with room. new StringBuilder(text.length()) reserves space for all 14 characters up front.
  2. The char overload. charAt(i) is a char, so toLowerCase returns a char and append adds it as a letter, not a number.
  3. No case, no change. The comma, spaces, 8, and ! pass through as they are; only H, L, L, J, A, V, and A change.

Example 2 — Count a Letter Without Caring About Case

Count every s and S in a phrase by lowercasing each character before comparing.

Java
public class CharacterToLowerCaseCount {
    public static void main(String[] args) {
        String phrase = "Mississippi STATE SALES";
        char target = 'S';
        int count = 0;
        for (char c : phrase.toCharArray()) {
            if (Character.toLowerCase(c) == Character.toLowerCase(target)) {
                count++;
            }
        }
        System.out.println("'" + target + "' appears " + count + " times");
    }
}

How It Works

  1. Normalise both sides. Lowercasing both the current character and the target means 'S', 's', and any mix match each other.
  2. Comparing chars with ==. char is a primitive, so == compares the values directly; no equals is needed.
  3. The tally. "Mississippi" has four s, "STATE" one S, and "SALES" two, so the total is 7.

Example 3 — Lowercase Code Points, Including One Above U+FFFF

The int overload handles Greek, accented Latin, and the Deseret alphabet (above U+FFFF). The char overload cannot handle the last one.

Java
public class CharacterToLowerCaseCodePoints {
    public static void main(String[] args) {
        int[] cps = {'Q', 0x00C9, 0x0391, 0x10400};
        for (int cp : cps) {
            System.out.println(cp + " -> " + Character.toLowerCase(cp));
        }
        String deseret = "\uD801\uDC00";
        System.out.println("char version on a surrogate: " + (int) Character.toLowerCase(deseret.charAt(0)));
    }
}

How It Works

  1. int in, int out. Because cp is an int, the code point overload runs and the results print as numbers: Q (81) becomes q (113), E with acute (201) becomes e with acute (233).
  2. Beyond the BMP. DESERET CAPITAL LETTER LONG I is U+10400 (66560); its lowercase partner is U+10428 (66600).
  3. The char overload gives up. The same letter stored in a String starts with the high surrogate 0xD801 (55297), which has no case, so toLowerCase(char) returns it unchanged.

Frequently Asked Questions

The same character. Digits, spaces, and punctuation have no lowercase form, so they are returned unchanged.
No. It always uses the Unicode simple case mapping. String.toLowerCase(Locale) is the locale-aware choice.
The int overload returns an int code point. Cast to char for BMP characters, or use new String(Character.toChars(cp)) for any code point.
Compare Character.toLowerCase(a) == Character.toLowerCase(b). For full Unicode accuracy also compare the uppercase forms, which is what String.equalsIgnoreCase does.
No. It always returns a single char or code point. Multi-character mappings only happen in String.toLowerCase.

Next: toString()

Turn a char, a Character, or (Java 11+) a code point into a String.

toString() tutorial →

About the author

Mari Selvan M P
Mari Selvan M P 🔗

Developer, cloud engineer, and technical writer

  • Experience 12 years building web and cloud systems
  • Focus Full Stack Development, AWS, and Developer Education

I write practical tutorials so students and working developers can learn by doing—from databases and APIs to deployment on AWS.

9 people found this page helpful