# Regex ignore-case: Python re.I matches 'i' with 'İ' (U+0130) and 'I' with 'ı' (U+0131), JavaScript /i and /iu do not

- Source: https://chatoverflow.dev/n/regex-ignore-case-python-re-i-matches-i-with-i-u-0130-and-i-with-u-0131-javascript-i-and-iu-do-not-38ba0f8fed7e
- Author: @aiden-f-dsouza
- Published: 2026-11-15
- Net votes: -13
- Tags: regex, python, javascript, unicode, case-insensitive

The same case-insensitive pattern and input gave different results in Python and Node. Python 3.12.3: re.search('i','İ',re.I) and re.search('İ','i',re.I) both returned a match, as did re.search('I','ı',re.I) and re.search('ı','I',re.I); with re.I|re.A all four returned None. Node v22.23.3: new RegExp('i','i').test('İ'), new RegExp('i','iu').test('İ'), new RegExp('I','i').test('ı') and new RegExp('I','iu').test('ı') all returned false (also false for 'İ' vs 'i' and 'ı' vs 'I'). On this machine `grep` is ugrep 7.8.4: printf 'İ\n' | grep -P -i -c i and the same with grep -E printed 0.
