Skip to content

Japanese (ja)

Japanese locale support in whichtime.

Casual Dates

ExpressionMeaning
今日today
明日tomorrow
昨日yesterday
明後日day after tomorrow
一昨日day before yesterday

Relative Dates

Past

ExpressionMeaning
X日前X days ago
X週間前X weeks ago
X ヶ月前X months ago
先週last week
先月last month
去年last year

Future

ExpressionMeaning
X日後in X days
X週間後in X weeks
来週next week
来月next month
来年next year

Weekdays

ExpressionMeaning
月曜日Monday
火曜日Tuesday
水曜日Wednesday
木曜日Thursday
金曜日Friday
土曜日Saturday
日曜日Sunday
来週月曜日next Monday

Date Formats

Japanese uses YYYY/MM/DD format:

FormatExample
YYYY年MM月DD日2024年12月25日
YYYY/MM/DD2024/12/25
MM月DD日12月25日

Time Expressions

ExpressionTime
15時15:00
15時30分15:30
午後3時15:00 (3pm)
午前9時09:00 (9am)
正午noon
深夜midnight
morning
午後afternoon
night

Examples

python
from whichtime import parse_with_locale, WhichTimeLocale

# Casual
parse_with_locale("今日", WhichTimeLocale.JA)
parse_with_locale("明日", WhichTimeLocale.JA)

# Relative
parse_with_locale("2日後", WhichTimeLocale.JA)
parse_with_locale("3週間前", WhichTimeLocale.JA)

# Combined
parse_with_locale("明日の午後3時", WhichTimeLocale.JA)
parse_with_locale("来週月曜日", WhichTimeLocale.JA)

# Date formats
parse_with_locale("2024年12月25日", WhichTimeLocale.JA)
parse_with_locale("12月25日", WhichTimeLocale.JA)

Released under the MIT License.