SWIFT Value Date Reader
A SWIFT value date is six characters, YYMMDD: the date of field 30, and the date at the front of the 32A subfield. Paste one and the tool says what it reads as. parseSwiftDate returns the ISO date, or the empty string when the text is not one, and isValidSwiftDate says whether it is. Everything on the page is what those calls returned. A last section goes the other way with formatSwiftDate.
The century is a rule, and the table is the library’s answer. The tool asks the library about the first of January of every two-digit year, from 00 to 99, and groups the years it reads alike. The rows of the century table are those groups. The table marks the row of the year you typed, and marks none when the text does not start with two digits. The rule is quoted under the table from SWIFT’s Standards MT General Information. The site never runs it.
T50. The SWIFT rules answer a malformed date with error code T50. The tool shows it for any refused text that is exactly six characters long. A refused text of any other length gets no code, because the date component is six characters and a longer string, such as a whole 32A subfield, was never a date. When a text is refused, the sentence under the verdict comes from asking the library again: is the year in a refused group, is the month a month, is the day a day, and, if all three are, the day does not exist in that month of that year. A refused 29 February names the year the library gave for the first of February of that year, so the tool does no leap-year sum of its own.
Writing a date. formatSwiftDate writes two digits for the year, so it refuses a year that two digits would read back as another year. The tool says so, with the range taken from the table. The box accepts a calendar date. A date-time names a calendar date only in a zone, so the tool asks for the date first.
import { parseSwiftDate } from "@northguild/gmt/finance/parse";import { formatSwiftDate } from "@northguild/gmt/finance/format";import { isValidSwiftDate } from "@northguild/gmt/finance/validate";
parseSwiftDate("240615"); // "2024-06-15"parseSwiftDate("990615"); // ""parseSwiftDate("750101"); // ""isValidSwiftDate("050229"); // falseformatSwiftDate("2024-06-15"); // "240615"formatSwiftDate("2000-12-31"); // ""Worth trying: a 19YY date is refused with T50, not read as 1999; a year past the last SWIFT reads is refused too, and the table marks its group; and 29 February 2005 has no such day. The FIX Timestamp Reader reads the other timestamp a payment message carries. The rules are in Finance: Message Timestamps.
© 2026 NorthGuild · Licences
Code examples: MIT-0. Packages: MIT. Third-party data and components: their own licences, credited where they appear. Everything else: © 2026 NorthGuild, all rights reserved.