SUBMIT A FILE TYPE CONTACT US SUPPORT ABOUT US

What Is an ICS File? How to Check a Calendar File Before You Trust It

ICS files are plain text calendar files, and the readers that open them can still accept damaged ones. Jump to your question below, or work through it in order.

44 min read Updated October 2026 Checked against sources and tests

What Is an ICS File? A plain text calendar file in the iCalendar format

Short answer

An ICS file is a plain text calendar file in the iCalendar format. It starts with the line BEGIN:VCALENDAR, stores events and other calendar items as lines of text, and ends with END:VCALENDAR. The ending .ics is a label, and the first line is what counts.

We read 423 ICS files and file pieces with six readers, and we damaged one ICS file in 50 ways. All six readers opened 187 of the 357 complete ICS files, and they split on 170. Of the 50 damaged copies, all six refused 5 and all six opened 18. Only 14 gave the same events in all four libraries.

To check ICS files without a calendar program, read the six steps. To see what is inside, read the layout. If your ICS file will not open, begin with the eight causes.

An ICS file is a calendar file in the iCalendar format. It is plain text, and its first line is BEGIN:VCALENDAR. The ending .ics is only a label, because the first line decides what an ICS file is.

Picture an email from a colleague with invite.ics attached, or a school site with an Add to calendar button. Open the download in a text editor and you can read it. An ICS file is text, and every line is a name, a colon and a value.

Wikipedia describes iCalendar as a format that the IETF defined in 1998, based on the older vCalendar format. RFC 2445 came out in November 1998. RFC 5545 replaced it in September 2009, and that is the text we checked our files against.

The IANA registry lists the type text/calendar with the endings .ics and .ifb. The ending .ifb is for free or busy time. The entry gives no magic number, so an ICS file has no binary signature, and the first line is the only sign.

Apple's iCal program is one program that reads the format, and the format is the IETF's. FileInfo files .ics as a calendar file from the IETF. It adds that two other kinds of file use the same ending, IronCAD 3D scenes and Sony IC Recorder sound files.

Where our ICS files come from

Our 423 ICS files and file pieces come from the test folders of seven public projects. icalendar gave 164, ical4j 107, node-ical 55, ical.js 46, libical 40, vobject 10 and sabre 1. The 423 files total 3,002,265 bytes, with a median of 616 bytes.

357 of the 423 files start with BEGIN:VCALENDAR, and we call them complete ICS files. The other 66 are file pieces, like a single event or a time zone, and 39 start with BEGIN:VEVENT. Many files are built to be odd, so they include cases that a calendar program does not write.

The ending is no guide. A file named ical4j_core.ics is a calendar with VERSION 1.0, 81 events and 657 lines. Our tests below also use 50 damaged ICS files made from one 1,364 byte file, 2,469 time zone files, 10 renamed copies and 8 other files.

ICS file facts at a glance

Quick facts about ICS files
Property Value
Meaning iCalendar. FileInfo files it as a calendar file from the IETF.
Endings .ics for calendar data and .ifb for free or busy time, per IANA.
Media type text/calendar, registered with IANA.
First line BEGIN:VCALENDAR. 357 of our 423 files start with it.
Magic number None. The IANA entry says so.
Text UTF-8. RFC 5545 says programs must write UTF-8 and must accept UTF-8 or ASCII.
Line ends CRLF. 135 of our 357 ICS files use it, and 217 use LF only.
Line length 75 bytes, then the line is folded. 57 of our ICS files have longer lines.
Required lines One VERSION and one PRODID. 77 of our files have no VERSION and 91 have no PRODID.
Opens with Calendar programs and libraries. We tested six readers on 423 files.
Our tests 423 files, 50 damaged copies, 2,469 time zone files, 10 renamed copies, 8 other files and 4 written files.

Wrong page? A file of contact cards starts with BEGIN:VCARD. A message with an invite inside is an EML file.

What Is Inside an ICS File? A stack of lines, with blocks that open and close

An ICS file is a stack of lines. A BEGIN line opens a block and an END line closes it. The lines between them are properties. Our example, base.ics, is 1,364 bytes and 52 lines long, with a time zone, a weekly meeting and an all day event.

We wrote one small calendar and called it base.ics, so every line can be read. It has one time zone, one meeting that repeats four times and one event that lasts all day. The figure shows its blocks from the outside in.

The layout of one calendar file from our tests, 1,364 bytes and 52 lines: a BEGIN:VCALENDAR line on line 1 and an END:VCALENDAR line on line 52, four calendar properties on lines 2 to 5, a time zone on lines 6 to 22, a meeting with an alarm on lines 23 to 43 and an all-day event on lines 44 to 51.
One calendar file from our tests, outside in. The blocks are not drawn to scale, and the line numbers come from a 1,364 byte file that we call base.ics.

Read the figure from the top. The first line is BEGIN:VCALENDAR and the last is END:VCALENDAR. The iCalendar specification puts the calendar properties first and the parts, called components, after them.

The first lines of an ICS file

The first 5 lines
head -n 5 base.ics
BEGIN:VCALENDAR
VERSION:2.0
PRODID:-//Example Corp//Team Calendar 1.0//EN
CALSCALE:GREGORIAN
METHOD:PUBLISH

VERSION:2.0 says which standard the ICS file follows, and RFC 5545 asks for it once. PRODID names the program that wrote the ICS file, and the RFC asks for it once too. CALSCALE:GREGORIAN names the calendar system, and METHOD:PUBLISH says the ICS file is shared and is not a request.

Every line has the same shape. A name comes first, then optional parameters after a semicolon, then a colon and the value. In DTSTART;TZID=America/New_York:20261103T140000 the name is DTSTART, the parameter names a time zone and the value is a local time.

Long lines and escaped commas

RFC 5545 asks for CRLF at the end of every line, and for lines of 75 bytes or fewer. A longer line is folded. The writer breaks it and starts the next physical line with one space or tab. A reader joins the lines again by dropping that space.

One value folded onto three lines
sed -n 30,32p base.ics
DESCRIPTION:Review the plan for the new site, the page list and the test re
 sults. Bring your notes\, the draft and a list of open questions for the t
 eam.

The three lines above are one line of 153 bytes. Commas inside values are written \, so that readers do not take them as separators. Semicolons become \;, backslashes become \\ and line breaks become \n.

Four time shapes

A time can be written four ways. The first is a local time with a zone name, like the meeting in base.ics. The second is a UTC time that ends in Z, like the DTSTAMP. The third is a floating time with no zone, and the fourth is a date with no time, like the closing day.

RFC 5545 names three forms for a date and time, floating, UTC and local with a zone reference. Dates use VALUE=DATE. The meeting starts at 2 pm in New York, and a reader that ignores the zone name would put it at another hour.

The lines you meet most

Lines in our ICS files
Line What we found
UID and DTSTAMP Identify an event and mark when it was written. RFC 5545 asks for both in every event. E6, the copy with no UID, was opened by all six readers, and E13, with no DTSTAMP, was opened by all six.
DTSTART and DTEND Start and end of an event. An event can use DURATION in place of DTEND, and the RFC allows only one of them. E5 uses both and five of six readers opened it.
RRULE A repeat rule like FREQ=WEEKLY;COUNT=4. 158 of our 357 ICS files use it. E7, a rule with no FREQ, was opened by all six.
ORGANIZER and ATTENDEE Who sent an invite and who is asked. 80 files have an organizer and 74 have attendees. E8, an attendee that is not an address, was opened by all six.
VALARM and TRIGGER Reminders inside events. 54 files have alarms. E10, with a TRIGGER that is not a duration, was opened by three readers.
VTIMEZONE and TZID A time zone and the name events use to point to it. 124 files have a definition. RFC 5545 asks for one for every zone name, and 50 of 153 files that name a zone have none.
METHOD Says what an ICS file is for. PUBLISH is in 67 files, REQUEST in 26 and REPLY in 4. The scheduling RFC defines how these messages work.

The list is small. Our script reads lines and blocks. It parses no date and it expands no repeat rule, so damage deeper in a value can pass it, as the damage tests show.

Which Kind of ICS File Do You Have? The ending names none of the parts, line ends or times

Four questions sort an ICS file, what parts it has, how its lines end, how its times are written and how big it is. Of 357 ICS files, 288 have events and 217 use LF where RFC 5545 asks for CRLF. The ending names none of this.

Most questions about ICS files come down to which parts are inside and how the lines are written. A text editor answers both in a minute, and our script answers in a second.

What our 357 calendar files contain: 288 have events, 124 have a time zone, 54 have an alarm and 24 have to-dos. 217 use LF line ends, 135 use CRLF and 5 mix them. 141 start events with a time zone name, 89 in UTC, 70 with a date only and 21 with a floating time.
The ending names none of these. 217 of 357 files use LF where RFC 5545 asks for CRLF, and 50 of the 153 files that name a time zone have no VTIMEZONE block.

Which parts an ICS file has

288 of our 357 ICS files have events, 124 have a time zone and 54 have an alarm. 24 have tasks, which the format calls VTODO. 21 have free or busy time and 17 have a journal entry. A file can have several parts, so the counts add to more than 357.

A calendar app reads events well. Wikipedia lists interoperability problems with tasks and journals. We tested no calendar app, so we cannot say which apps show tasks.

How the lines are written

217 of 357 ICS files use LF line ends, 135 use CRLF and 5 mix them. RFC 5545 asks for CRLF. 119 files fold at least one line, and 57 have a line over 75 bytes. 30 of those 57 are files with LF line ends.

36 files have characters outside ASCII, and 161 have a private property that starts with X-. 77 files have no VERSION line and 91 have no PRODID line. 275 have VERSION:2.0.

How event times are written

We counted the DTSTART lines outside time zone definitions. 141 files use a zone name, 89 use a UTC time, 70 use a date only and 21 use a floating time. 8 use another form. A file can use more than one form.

The program that wrote an ICS file leaves a mark in PRODID. Apple Computer wrote 24 of our files, Google 21 and Mozilla 17. The mark is a label that a program writes about itself, so it proves nothing about the program.

The ending is not the type A file named ical4j_core.ics is a calendar of 81 events with VERSION 1.0.
The ending is not the line end 217 of 357 ICS files use LF only, and 135 use CRLF.
Parts differ Files have 1 or more of 6 kinds of part. 288 have events and 17 have a journal.
Times differ 141 files use zone names, 89 use UTC, 70 use dates and 21 use floating times.

Not sure the file is an ICS file at all? Check it with our script.

What Did We Find in 423 Calendar Files? Six readers, and a split on 170 of 357 calendars

We read 423 ICS files and file pieces from seven public projects with six readers. Our script opened 356 of 357 ICS files, the file command 349, ical.js 318, icalendar 306, vobject 301 and ics.py 205. All six opened 187 together, and the readers split on 170.

We took the files from the test folders of icalendar, ical4j, node-ical, ical.js, libical, vobject and sabre. They are public test files and not a sample of the ICS files on a typical PC. Many are odd on purpose.

The readers were the file command 5.45, our 57 line Python script, icalendar 7.3.0, vobject 0.9.9, ics.py 0.7.3 and ical.js 2.2.1. We worked on Linux with Python 3.13 and Node 22. We opened no ICS file in Google Calendar, Outlook or Apple Calendar.

A reader opened an ICS file when it returned the calendar and gave no error. That is a light test, because it asks for the calendar and not for the right one. So we also compared the events that the four libraries returned.

423 ICS files and file pieces read
6 readers on every file
50 damaged copies of one ICS file
2,301 events in 188 calendars read four ways
Six readers on the same 357 calendar files: our script opened 356, the file command 349, ical.js 318, icalendar 306, vobject 301 and ics.py 205. All six opened 187 files together and the readers split on 170.
Six readers on 357 calendar files. The 66 other files in our set are fragments, and the three libraries that opened them are listed in the text.
What six readers found in 423 ICS files and file pieces
Test Result
Opened Of 357 ICS files, our script opened 356, the file command 349, ical.js 318, icalendar 306, vobject 301 and ics.py 205.
Together All six readers opened 187 ICS files. No file was refused by all six, and the readers split on 170.
File pieces Of the 66 files that do not start with BEGIN:VCALENDAR, ical.js opened 55, vobject 52 and icalendar 51. The file command, our script and ics.py opened none.
Events The four libraries opened 188 calendars together. All four counted the same number of events in all 188, 2,301 in total. Titles differed in 7 files, start days in 8, descriptions in 10 and locations in 1.
Time zones Of 2,469 time zone files, the file command, our script, vobject and ical.js opened all. icalendar opened 1,696 and ics.py opened 1,694.
Sizes From 0 to 1,044,540 bytes. The median is 616, and the 423 files total 3,002,265 bytes.
Compression gzip level 9 cut the 423 files to 14.5 percent of their size, and xz cut them to 7.4 percent.

All six readers opened 187 of the 357 ICS files, and no file was refused by all six. The other 170 split the readers. The libraries are the strict ones, and the file command and our script are the easy ones.

The 170 files that split the readers

ics.py refused 152 ICS files. 79 have no PRODID line, and 20 contain more than one calendar. vobject refused 56, 10 of them for a date or time that is not valid. ical.js refused 39, and 12 of those have an invalid date and time, 8 have an invalid line and 5 begin a block that never ends.

icalendar refused 51. 17 contain more than one calendar and 8 have a property it cannot read. The libraries read the entire file, so one bad line can lose the calendar. The file command and our script read the first lines only.

The file command refused 8 ICS files. They start with a byte order mark, blank lines or spaces, or have a stray control character on the first line, like ical.js_newline_junk.ics. Our script refused libical_malloc.ics, which has zero bytes in its first lines, and only the file command opened it. 19 files were refused by all four libraries.

The time zone files

We read 2,469 time zone files from libical and ical4j after removing 514 duplicates. icalendar refused 773 of them and ics.py refused 775. 767 of the files have a TZID-ALIAS-OF line and 6 have a TZUNTIL line, and both libraries stop at them with an unsupported property error. The other 2 ICS files that ics.py refused stay unexplained.

RFC 7808 defines both lines. It came out in March 2016, more than six years after RFC 5545. The file command, our script, vobject and ical.js read all 2,469 files.

How big the files are

279 of our 423 files are under 1 KB and 111 are between 1 KB and 9.9 KB. 30 are between 10 KB and 99 KB, and 3 are 100 KB or more. The biggest is 1,044,540 bytes. One file has 0 bytes.

Readers differ Our script opened 356 ICS files and ics.py 205. Use a second reader on any ICS file you rely on.
One line decides ics.py refused 79 files for a missing PRODID line. A reader can stop at one line.
Newer lines split them icalendar and ics.py refused 773 time zone files that use lines from RFC 7808.
Opened is not the same The four libraries gave the same event counts for 188 calendars and different titles for 7.

Read the study with care. It shows what six readers do with 423 public test files. Many are odd on purpose, and a reader that agrees on our files can still fail on your ICS file. We opened no ICS file in a calendar app.

What Do Readers Do With a Damaged Calendar? 50 broken copies, six readers and 27 split decisions

We damaged one 1,364 byte ICS file in 50 ways. All six readers refused 5 copies, all six opened 18 and the readers split on 27. Our script opened 44, the file command 40 and ics.py 22. Only 14 copies came back with the same events in all four libraries.

The 50 damaged ICS files are copies of base.ics and come in six groups. Group A changes the structure lines, B the first bytes and C cuts the ICS file short. D changes line ends and folding, E changes values and F adds or changes bytes. Every copy changes one thing.

We asked two questions about every copy. Did the six readers open it? And did the four libraries return the same events as for the intact file? Same events means the same UID, title, times, repeat rule, description, location, attendees and alarms. A copy that removes a start cannot match, so read the groups other than E first.

A grid of 50 damaged copies of one calendar file and six readers. All six readers refused 5 copies, all six opened 18 and the readers split on 27. Only 14 copies came back with the same events in all four libraries.
Rows are damaged copies. The first six columns show whether a reader opened the copy. The last four show whether the library returned the same events as the intact file.

The 5 copies that every reader refused

Copies A1, B5, B6 and C1 broke the first line. A1 removes BEGIN:VCALENDAR, B5 removes the first 6 bytes, B6 changes the first letter to X and C1 cuts the ICS file at 5 bytes. B2 saves the ICS file as UTF-16 with a byte order mark.

All five copies change the first line or the first bytes. Our script names B2 as UTF-16 or binary data, and it says that A1 starts with the line VERSION:2.0.

The 18 copies that every reader opened

Some damage in an ICS file went unseen. A missing VERSION line (A3), a VERSION of 1.0 (A4) and a missing last byte (C5) passed all six readers, and all four libraries returned the same events. So did tabs for folding spaces (D7), a blank line inside an event (D8) and an attendee with no address (E8).

Line ends and folding passed too. An ICS file with LF only (D1) and an ICS file with alternating line ends (D3) matched in all four libraries. So did an ICS file with every folded line joined into one (D4) and an ICS file with lines folded at 20 bytes (D11).

Three more copies passed. A missing DTSTAMP (E13), an extra property that starts with X- (F4) and an unknown component (F5) matched in all four libraries.

Opened does not mean the same events. E1 removes DTSTART and E6 removes the UID. E4 names a time zone that is not defined, E7 has a repeat rule with no FREQ and E9 has a comma in a location. All six readers opened all five, and at least one library returned different events from the intact file.

The 27 copies that split the readers

Of the 50 damaged ICS files, ics.py opened only 22 and vobject 29, fewer than any other reader. The libraries icalendar and ical.js opened 30, the file command 40 and our script 44.

An ICS file with no PRODID (A5) was refused by ics.py only. A lower case BEGIN:VCALENDAR (A8) was refused by the file command and ics.py. A byte order mark in front (B1) and an email header in front (B4) split the readers. Only our script and icalendar opened B1, and only vobject opened B4.

Cuts split them too. The file command and our script opened an ICS file cut after the first line (C2), in the middle of the first event (C3) and 100 bytes short (C6). They read only the start. The libraries refused all three. A file cut in half (C4) was also opened by ics.py.

Line ends split the readers. A file with CR line ends only (D2) was opened by the file command, our script, vobject and ics.py. icalendar and ical.js refused it. Continuation lines with no leading space (D5) made the libraries vobject, ics.py and ical.js refuse the ICS file.

Extra bytes at the end split them too. 64 KB of random bytes (F1) was opened by the file command and our script only. 100 bytes of text (F2) was also opened by vobject and a second copy of the ICS file (F3) by ical.js too. icalendar and ics.py refused F3.

What our script passes

Our script opened 44 of the 50 damaged ICS files. Of those 44, 30 did not come back with the same events in all four libraries, because the script parses no date and reads no value. A pass from the script means the first line and the blocks make sense. It does not mean the events read correctly.

Readers differ The six readers split on 27 of 50 damaged ICS files. Use two readers on any ICS file you care about.
Line ends mostly pass LF only, alternating line ends, unfolded lines and lines folded at 20 bytes matched in all four libraries.
The first line is checked All six readers refused the 5 copies that broke the first line, removed the first bytes or saved the ICS file as UTF-16.
Opened is not the same 5 of the 18 damaged ICS files that all six readers opened returned different events in at least one library.

Read the grid with care. Every copy changes one thing in one ICS file that we wrote. Damage in the wild changes many things at once. We opened no copy in Google Calendar, Outlook or Apple Calendar.

What Does Our Expert Say About ICS Files? A note from Neeraj Singh on trusting one reader

Check ICS files with two readers before you trust one answer. Six readers opened 187 of 357 ICS files together and split on 27 of 50 damaged ICS files. A first line check takes seconds, and an event list from a second reader takes a little longer.

Neeraj Singh

Expert insight

“ICS files look like one more calendar download, so people trust the first program that opens them. Six readers split on 170 of our 357 ICS files, and only 14 of 50 damaged copies matched in all four libraries. Check every ICS file with two readers and read the first line before you trust the ending.”

Neeraj Singh Manager, Tech Support & Operations 19+ years fixing Windows and system errors

Why one reader proves little

A reader that opens an ICS file shows that the first lines and the blocks make sense. It does not show that every event reads right. In our tests our script opened 44 of 50 damaged ICS files, and only 14 of the 50 matched in all four libraries.

The check has a limit. Two readers that agree can both be wrong, and neither says whether the meeting is in your calendar at the right hour. The script from the check reads lines and blocks. Compare its answer with a library and read the dates yourself.

Copy the ICS file before you touch it. Write down the SHA256 hash of the original and work on a copy. The hash shows which ICS file you received, and it lets you spot a changed download later.

How Do You Open an ICS File? Three import pages, six readers and two outside viewers

Calendar programs open ICS files, and Google, Microsoft and Apple all have an import page for them. We tested six other readers on 423 files instead, and we opened no file in a calendar app.

The table lists the three vendor pages we read and the readers we tested. The readers with a version number are the ones we tested. We worked on Linux, so we imported no ICS file into Google Calendar, Outlook or Apple Calendar.

Programs that open ICS files
Program What it does
Google Calendar The Google import page says you can import ICS and CSV files on a computer, through Settings and Import & Export. It says guests and conference data are not imported and that imported events do not stay in sync. We tested nothing here.
Outlook.com and Outlook on the web The Microsoft import page says to select Add calendar and then Upload from file. An import is a snapshot, and the calendar does not refresh the imported events. We tested nothing here.
Apple Calendar The Apple import page says to drag the ICS file into Calendar or to choose File, then Import. It warns that importing an ICS file removes the custom colors of events. We tested nothing here.
The file command Version 5.45. It names the type from the first lines and opened 349 of 357 ICS files. It refuses an ICS file with blank lines or a byte order mark in front.
Our script A 57 line Python script that reads the lines and blocks. It opened 356 of 357 ICS files and parses no date.
icalendar A Python library, version 7.3.0. It opened 306 ICS files and returns events, times and time zones.
vobject A Python library, version 0.9.9. It opened 301 ICS files and writes files as well.
ics.py A Python library, version 0.7.3. It opened 205 ICS files and refuses an ICS file with no PRODID line.
ical.js A JavaScript library, version 2.2.1. It opened 318 ICS files and 55 of the 66 file pieces.
A text editor Any text editor shows the lines. Saving with another encoding breaks the ICS file, because all six readers refused the UTF-16 copy (B2).

The Google page adds that the ICS file must begin with BEGIN:VCALENDAR and end with END:VCALENDAR, and that every event must be wrapped in BEGIN:VEVENT and END:VEVENT. That matches what we saw. All six readers refused the copies that lost or broke the first line (A1, B5, B6 and C1).

Open ICS files on the command line

Two commands show what an ICS file contains. The file command names the type and prints a note when the line ends are not CRLF. The grep command counts the events in base.ics. A file from the ical.js tests with LF line ends gets the second note.

Two ways to look at an ICS file
file -b base.ics ical.js_Denver.ics
iCalendar calendar file
iCalendar calendar file, without CRLF
grep -c '^BEGIN:VEVENT' base.ics
2

The first line of output is for base.ics and the second is for ical.js_Denver.ics. The words without CRLF mean that the ICS file uses LF only, and RFC 5545 asks for CRLF. Both files are fine to read, and 217 of our 357 ICS files use LF.

Open ICS files with Python

The Python package icalendar reads the same file. Four lines print the start and the title of every event in an ICS file. The decoded call changes the start into a date and time, so a bad date fails here and not at the open.

Print every event
from icalendar import Calendar
cal = Calendar.from_ical(open('base.ics', 'rb').read())
for event in cal.walk('VEVENT'):
    print(event.decoded('DTSTART'), event.get('SUMMARY'))
2026-11-03 14:00:00-05:00 Planning meeting at the Café
2026-11-25 Office closed

The first event starts at 2 pm in New York, which is UTC minus 5 hours in November, and the second is a date with no time. icalendar failed on 51 of the 357 ICS files and on 20 of the 50 damaged ICS files. The damage grid lists the copies.

Viewers and converters for ICS files

These two links open outside pages for ICS files. One comes from SysTools and one from Freeviewer. We describe them from their own pages and tested neither.

SysTools ICS Converter

Converts ICS files to other formats

Windows and Mac

Freeviewer ICS Viewer

Opens ICS files, damaged ones too

Windows viewer

The SysTools ICS Converter lists PST, MSG, PDF, HTML, iCal, TXT, CSV, VCS and ICS among its outputs. Its page names Windows 7 to 11 and macOS 11 and later. The page says its demo converts 10 items and that the tool sets no file size limit.

Freeviewer's page describes a free viewer for Windows that opens ICS files. It lists an advanced scan for damaged files and says it cannot save or export a file. We list no prices, because they change.

Install a viewer from its maker. Download a viewer from the maker's own page, and write down the file hash if the page gives one. ICS files do not need special software, and our six readers worked without any.

How Do You Check an ICS File? Six steps, and only one of them reads values

Check ICS files in six steps. Read the first line, then the next lines, then the entire file with our 57 line script. Only the last step reads values. The script reads lines and blocks, and it stops there.

The first reads need no Python. The head command prints the first lines, and the file command names the type of an ICS file. For base.ics they show BEGIN:VCALENDAR, VERSION:2.0 and a PRODID line.

Steps 2 and 3 on one ICS file
head -n 5 base.ics
BEGIN:VCALENDAR
VERSION:2.0
PRODID:-//Example Corp//Team Calendar 1.0//EN
CALSCALE:GREGORIAN
METHOD:PUBLISH
file -b base.ics
iCalendar calendar file

Read the first line from the top. BEGIN:VCALENDAR opens the calendar. VERSION:2.0 is the standard, and PRODID names the program that wrote the ICS file. The file command prints the same type as words.

Step 4 reads every line of the ICS file. The script joins folded lines, counts the blocks and checks that every BEGIN has an END. It does not read a date, and it never changes the ICS file.

Check ICS files with Python

The script reads the ICS file as text and prints the type, the line ends, the length of the lines and the block counts. It names a problem as a warning and refuses a file that does not start with BEGIN:VCALENDAR. It parses no date and never changes an ICS file.

Read the shape of an ICS file
#!/usr/bin/env python3
"""ics_peek.py - check the shape of an ICS file. It parses no dates and never changes the file.
Usage: python3 ics_peek.py FILE [FILE ...]
"""
import re, sys
from collections import Counter

def peek(path):
    raw = open(path, 'rb').read()
    out, warn = [], []
    if raw[:3] == b'\xef\xbb\xbf':
        warn.append('starts with a UTF-8 byte order mark')
        raw = raw[3:]
    if raw[:2] in (b'\xff\xfe', b'\xfe\xff') or b'\x00' in raw[:64]:
        return '%s: UTF-16 or binary data, the first bytes are %s' % (path, raw[:8].hex(' '))
    try:
        text = raw.decode('utf-8')
    except UnicodeDecodeError as e:
        warn.append('not valid UTF-8 at byte %d' % e.start)
        text = raw.decode('utf-8', 'replace')
    crlf = text.count('\r\n')
    lf, cr = text.count('\n') - crlf, text.count('\r') - crlf
    ends = 'CRLF' if crlf and not (lf or cr) else 'LF' if lf and not (crlf or cr) else 'CR' if cr and not (crlf or lf) else 'mixed' if crlf + lf + cr else 'none'
    lines = [x for x in re.split(r'\r\n|\n|\r', text) if x.strip()]
    if not lines or lines[0].strip().upper() != 'BEGIN:VCALENDAR':
        return '%s: not an ICS file, the first line is %r' % (path, lines[0][:30] if lines else '')
    logical = []
    for x in lines:
        if x[0] in ' \t' and logical:
            logical[-1] += x[1:]
        else:
            logical.append(x)
    stack, kinds = [], Counter()
    for x in logical:
        name, _, value = x.partition(':')
        if name.upper() == 'BEGIN':
            stack.append(value.strip().upper()); kinds[stack[-1]] += 1
        elif name.upper() == 'END':
            if not stack or stack.pop() != value.strip().upper():
                warn.append('END:%s does not match a BEGIN' % value.strip())
    if stack:
        warn.append('missing END for %s' % ', '.join(stack))
    version = next((x.partition(':')[2] for x in logical if x.upper().startswith('VERSION:')), None)
    if version is None:
        warn.append('no VERSION line')
    elif version.strip() != '2.0':
        warn.append('VERSION is %s and an iCalendar file needs 2.0' % version.strip())
    long = sum(len(x.encode()) > 75 for x in lines)
    out.append('%s: iCalendar, VERSION %s, %d lines, %s line ends, %d lines over 75 bytes' % (path, version, len(lines), ends, long))
    parts = ['%d %s' % (n, k) for k, n in kinds.items() if k != 'VCALENDAR']
    if parts:
        out.append('  components: ' + ', '.join(parts))
    out += ['  warning: ' + w for w in warn]
    return '\n'.join(out)

for p in sys.argv[1:]:
    print(peek(p))

Here is what it printed for three files. They are base.ics, a time zone file with LF line ends and a long calendar with 81 events and a VERSION of 1.0.

Three files
python3 ics_peek.py base.ics ical.js_Denver.ics ical4j_core.ics
base.ics: iCalendar, VERSION 2.0, 52 lines, CRLF line ends, 0 lines over 75 bytes
  components: 1 VTIMEZONE, 1 STANDARD, 1 DAYLIGHT, 2 VEVENT, 1 VALARM
ical.js_Denver.ics: iCalendar, VERSION 2.0, 41 lines, LF line ends, 0 lines over 75 bytes
  components: 1 VTIMEZONE, 2 DAYLIGHT, 2 STANDARD
ical4j_core.ics: iCalendar, VERSION 1.0, 657 lines, CRLF line ends, 108 lines over 75 bytes
  components: 81 VEVENT
  warning: VERSION is 1.0 and an iCalendar file needs 2.0

The first line of every answer gives the version, the number of lines, the line ends and the lines over 75 bytes. The second line lists the blocks. A warning follows when something is off, like the old version of ical4j_core.ics.

Six problem files
python3 ics_peek.py A1.ics B2.ics C3.ics E11.ics vcard.ics invite.ics
A1.ics: not an ICS file, the first line is 'VERSION:2.0'
B2.ics: UTF-16 or binary data, the first bytes are ff fe 42 00 45 00 47 00
C3.ics: iCalendar, VERSION 2.0, 26 lines, CRLF line ends, 0 lines over 75 bytes
  components: 1 VTIMEZONE, 1 STANDARD, 1 DAYLIGHT, 1 VEVENT
  warning: missing END for VCALENDAR, VEVENT
E11.ics: iCalendar, VERSION 2.0, 52 lines, CRLF line ends, 0 lines over 75 bytes
  components: 1 VTIMEZONE, 1 STANDARD, 1 DAYLIGHT, 2 VEVENT, 1 VALARM
  warning: not valid UTF-8 at byte 697
vcard.ics: not an ICS file, the first line is 'BEGIN:VCARD'
invite.ics: not an ICS file, the first line is 'From: ana@example.com'

A1 is an ICS file that lost its first line, and B2 is saved as UTF-16. C3 was cut in the middle of an event, so the script names the missing END lines. E11 has a byte that is not valid UTF-8. The last two files are a contact card and an email that have the ending .ics.

What the script found in our files

Our script on ICS files and damaged ICS files
Result Cases
Read (356 of 357) The script read 356 ICS files. 270 gave no warning and 86 gave at least one. 77 had no VERSION line, 7 had a missing END line, 4 were not valid UTF-8 and 4 had a VERSION other than 2.0.
Refused (1 of 357) It refused libical_malloc.ics, which has zero bytes in its first lines. Only the file command opened that file.
Other files (66 and 8) It refused all 66 file pieces that do not start with BEGIN:VCALENDAR, and all 8 other files that we named .ics.
Refused copies (6 of 50) It refused A1, B2, B4, B5, B6 and C1.
Passed with differences (30 of 44) The script passed 44 damaged ICS files, and 30 of those did not come back with the same events in all four libraries, because the script reads no value.

The script reads lines and nothing else. It does not read a date or expand a repeat rule. ICS files with broken values can pass it, so the damaged ICS files matter.

Check order for any ICS file

  1. Copy the ICS file, write its SHA256 hash and work on the copy.
  2. Read the first line of the ICS file. It must be BEGIN:VCALENDAR. A line like BEGIN:VCARD or From: means another type.
  3. Read the next lines. Look for VERSION:2.0 and a PRODID line, which RFC 5545 asks for once.
  4. Read the ICS file with our script. Warnings name missing END lines, bad encodings and missing VERSION lines.
  5. Compare with the file command and with libraries like icalendar. Differences point to damage or reader limits.
  6. Print the events with a library, as in the Python example, and compare the dates, zone names and titles with what you expect. Only this step reads values.

Is an ICS File Safe to Open? Reading is safe, and a name proves nothing

Reading an ICS file with a reader is safe, because an ICS file is text. The name proves nothing. All six readers read a renamed ICS file under all 10 names, and 8 other files with the ending .ics were not calendars.

We opened no ICS file in a calendar app and scanned none for malware. The six readers only read text. The files come from public test folders, so their contents are not the worry here.

Reading the lines of an ICS file Safe. Our readers only read text.
Writing down the hash Safe, and it shows which ICS file you received.
Alarms in a file ACTION:EMAIL is in 13 of our files and ACTION:PROCEDURE in 5. RFC 5545 deprecates PROCEDURE. We opened no file in a calendar app, so we cannot say which apps act on these.
Links in a file 24 of our files have an ATTACH line, and 14 of them point to an http address. 35 files have a URL line. Links point to pages or files, and we followed none.
Trusting the name Files named .ics can be zips, CSVs or contact cards, and calendars named .txt stay calendars. Our readers read a renamed ICS file under every name.
Invites from strangers 80 of our files name an organizer and 74 name attendees. Any program can write those names, so an invite proves nothing about its sender.

The rename test

We copied base.ics to 10 names, like base, base.ICS, base.csv, base.eml, base.html, base.ical, base.ics.txt, base.ifb, base.txt and base.vcs. All six readers opened all 10, so none of them trusts the ending.

The reverse also works. We gave 8 other files the ending .ics. They are a zip archive, an empty file, a CSV list of events, a jCal file, an email, a text note, a web page and a contact card. The file command, our script and ics.py refused all 8.

The libraries were less strict. icalendar and ical.js opened the contact card, and vobject opened the contact card and the email. A reader that opens a file has read lines in the same shape, and that is not proof of a calendar. Show full file names and read the first line of anything you doubt.

What an ICS file can contain

An ICS file stores lines of text, so it contains no program. It can contain links and private properties. 24 of our ICS files have an ATTACH line, 35 have a URL line and 16 have a TZURL line that names a time zone source.

5 files have an X-ALT-DESC line, a private property that stores an HTML version of the description, with its own text and links. The iCalendar RFC lists AUDIO, DISPLAY and EMAIL as alarm actions and deprecates PROCEDURE, and 5 of our files still use it.

Invites in your inbox

A calendar invite is an ICS file inside an email, and the METHOD line says what it is for. REQUEST is in 26 of our files and REPLY in 4. See the EML file page for the message side and the iTIP specification for how the methods work.

We tested no mail program. An invite from an unknown sender is still a message from an unknown sender, so check who wrote it before you accept. Saving the attached ICS file and reading it with our script shows what it contains without adding it to your calendar.

Not sure? Check it first. Copy the hash, read the lines with the ICS script and compare another reader. If the ICS file came in an email you did not expect, delete the message and ask the sender through another route.

Why Will Your ICS File Not Open? Eight causes, and what to do about every one

Most ICS files that will not open fail for one of eight reasons. Read the first line first, then the entire file, then the events. Our six readers refused 5 of 50 damaged ICS files and opened 18, and 5 of those 18 still returned different events.

We read 423 files and 50 damaged ICS files with six readers. The table groups what we saw into eight causes. The number in brackets matches the cause.

Every row says what happens to the ICS file and what to try. The fixes work on a copy, and none changes the original. A reader that says nothing is no sign that the events read right.

Eight causes of ICS files that will not open
Cause Result and fix
A broken first line (1) All six readers refused 5 of our 50 damaged ICS files, and all 5 broke the first line or the first bytes. A byte order mark in front (B1) was opened by our script and icalendar only. An email header in front (B4) was opened by vobject only. Fix: Open a copy in a text editor, make BEGIN:VCALENDAR the first line with nothing before it and save as UTF-8. We tested no repair.
A cut copy (2) A copy cut at 5 bytes was refused by all six readers. Copies cut after the first line, in the middle of an event or 100 bytes short were opened by the file command and our script only, which read the start. Fix: Compare the size and the hash with the source, then copy the ICS file again.
A file that is not a calendar (3) A zip, a CSV list, a jCal file, an email, a web page or a contact card named .ics is not an ICS file and has no BEGIN:VCALENDAR line. The file command, our script and ics.py refused all 8 of our other files, and three libraries opened the contact card. Fix: Read the first line. If it is not BEGIN:VCALENDAR, name the type with the file command and open the file as that type.
A missing required line (4) ics.py refused 79 of 357 ICS files because they have no PRODID line. A copy with no PRODID (A5) was refused by ics.py only, and a copy with no VERSION (A3) was opened by all six readers. Fix: Add a PRODID line to a copy and read it again.
Broken values (5) An ICS file with a start in month 13 (E2) was opened by the file command, our script and ical.js only. A line with no colon (E12) was opened by the file command, our script and icalendar. In the files we read, ical.js refused 12 for a date it could not read and vobject refused 10. Fix: Print the events with a library, then correct the line that the error names.
Line ends and folding (6) ICS files with CR line ends (D2) were refused by icalendar and ical.js. Continuation lines with no leading space (D5) were refused by vobject, ics.py and ical.js. LF only, tabs, unfolded lines and lines folded at 20 bytes matched in all four libraries. Fix: Save with CRLF line ends and start every folded line with a space.
Several calendars or extra bytes (7) ics.py refused 20 ICS files that contain more than one calendar, and icalendar refused 17. 64 KB of random bytes after the end (F1) were opened by the file command and our script only. Fix: Keep one calendar in every file and delete everything after END:VCALENDAR.
A strict reader (8) ics.py opened only 205 of 357 ICS files, and the file command refused 8 that start with a byte order mark, blank lines or spaces. A refusal from one reader is no proof that the ICS file is lost. Fix: Try a second reader, like our script, icalendar or ical.js, before you decide.

Check ICS files that will not open, step by step

We tested the reading steps on Python 3.13 and Linux. We opened no ICS file in a calendar app, and the steps keep the original untouched at every point.

  1. Copy the ICS file, write its SHA256 hash and work on the copy.
  2. Read the first line with the check steps. If it is not BEGIN:VCALENDAR, name the type with the file command.
  3. Read the ICS file with the script. A warning names the point where the ICS file stops making sense.
  4. Compare with the file command, as in the command line example. A type of iCalendar calendar file means the first lines make sense.
  5. Print the events with a library, as in the icalendar example, and compare the dates and titles with what you expect.
  6. If the ICS file is smaller than the source says, copy it again and compare the hash.
  7. If one reader refuses the ICS file, try another before you decide, as the split files show.

What to send a helper

Short messages about an ICS file get faster answers. Include the details below, and add the script output. Its first line gives the version, the line count and the line ends, and later lines name every block.

A message that gets an answer
Subject: ICS file will not open
File: name, size in bytes and SHA256 hash
First lines: the output of ics_peek.py
Reader: name, version and the exact words of the error
Platform: Windows, Mac or Linux and the program you used
Source: where the ICS file came from and when it was copied

What no step can fix

A lost first line or a cut file Files that lost their first bytes or their end need new copies or backups. We found no tool that rebuilds the lost events.
Broken values The first line and the blocks can look fine while a date reads wrong. Only the sender can say what the date should be.
A strict reader ics.py opened 22 of the 50 damaged ICS files and our script 44. A refusal from one reader is not proof that the ICS file is lost.
A file with another type Read the first line and open it as the type it is.
A wrong ending The ICS file is fine. Copy it to a name that ends in .ics and try again.

Do not try online repair sites. A site that offers to fix or convert any ICS file for free can keep the upload. An invite names people, places and times, as the privacy check shows. Try the steps above on a copy first.

How Do You Make an ICS File? Four writers, one meeting and four ways to write the time

icalendar, vobject, ics.py and ical.js all wrote the same 2 pm meeting. The four files are 405 to 1,132 bytes long, and they write the time four ways. icalendar names a zone and never defines it, vobject defines it, ics.py writes UTC and ical.js writes a floating time.

Writing an ICS file means writing lines. We tested four writers on one event, a meeting at 2 pm on 3 November 2026 in New York that lasts one hour. The table lists what the four wrote, and every row ends with the tests behind it.

What four writers wrote for one meeting
Writer What it wrote
icalendar Wrote 484 bytes. The start is DTSTART;TZID=America/New_York, and the ICS file has no VTIMEZONE block, so the zone name is used and never defined. All six readers opened it. Source: Our tests.
vobject Wrote 1,132 bytes on 46 lines. It added a VTIMEZONE block named EST with two STANDARD and two DAYLIGHT rules. All six readers opened it. Source: Our tests.
ics.py Wrote 405 bytes. The start is the UTC time 20261103T190000Z, so the zone name is gone. The description is one line of 154 bytes and is not folded. All six readers opened it. Source: Our tests.
ical.js Wrote 412 bytes. The start is the floating time 20261103T140000, because our code gave it no zone. One folded line is 76 bytes, one byte over the limit. All six readers opened it. Source: Our tests.

Write an ICS file from Python

The Python code below made the icalendar file. The other three writers used the same title, place, description and times. The last command lists the size of all four files.

One writer, four files
import datetime as dt, zoneinfo, icalendar
ny = zoneinfo.ZoneInfo('America/New_York')
start = dt.datetime(2026, 11, 3, 14, 0, tzinfo=ny)
text = 'Review the plan for the new site, the page list and the test results. Bring your notes, the draft and a list of open questions for the team.'
cal = icalendar.Calendar()
cal.add('prodid', '-//Example Corp//Writer Test//EN')
cal.add('version', '2.0')
event = icalendar.Event()
event.add('uid', 'w1@example.com')
event.add('dtstamp', dt.datetime(2026, 10, 1, 12, tzinfo=dt.timezone.utc))
event.add('summary', 'Planning meeting at the Café')
event.add('dtstart', start)
event.add('dtend', start + dt.timedelta(hours=1))
event.add('location', 'Café Central, Room 4')
event.add('description', text)
cal.add_component(event)
open('out_icalendar.ics', 'wb').write(cal.to_ical())
ls -l out_*.ics | awk '{print $5, $9}'
484 out_icalendar.ics
412 out_icaljs.ics
405 out_ics.ics
1132 out_vobject.ics

Our script reads all four files. The vobject file has the most lines, because it writes the time zone rules. The ics.py and ical.js files both have one line over 75 bytes.

All four files
python3 ics_peek.py out_icalendar.ics out_vobject.ics out_ics.ics out_icaljs.ics
out_icalendar.ics: iCalendar, VERSION 2.0, 15 lines, CRLF line ends, 0 lines over 75 bytes
  components: 1 VEVENT
out_vobject.ics: iCalendar, VERSION 2.0, 46 lines, CRLF line ends, 0 lines over 75 bytes
  components: 1 VTIMEZONE, 2 STANDARD, 2 DAYLIGHT, 1 VEVENT
out_ics.ics: iCalendar, VERSION 2.0, 12 lines, CRLF line ends, 1 lines over 75 bytes
  components: 1 VEVENT
out_icaljs.ics: iCalendar, VERSION 2.0, 14 lines, CRLF line ends, 1 lines over 75 bytes
  components: 1 VEVENT

Where the time zone gets lost

Two of the four ICS files can read wrong elsewhere. The icalendar file names America/New_York and never defines it, and RFC 5545 asks for a definition. 50 of the 153 files in our set that name a zone do the same. The ical.js file has a floating time, which a program reads as 2 pm in its own zone.

Of the four ICS files, the ics.py file is the safest for time. It writes 7 pm in UTC, which is the same moment as 2 pm in New York in November. It loses the zone name, so a program that wants to show the meeting in New York has to know that already.

Notes on exports from apps

Apple's page says the Export command writes a single calendar as an ICS file and that Calendar Archive writes an .icbu file for all calendars. Microsoft's page says to save a calendar as an ICS file before you import it. Google's page says an ICS file exported from Google Calendar is a formatting example.

We tested no export in an app. We tested whether four writers can write an ICS file and whether six readers can open it. We did not test whether a calendar app shows the time right.

Keep the original. Write a new ICS file instead of editing the old one, and keep the old file with its hash. A writer that drops the zone name, as ics.py does, cannot get it back.

How Does an ICS File Differ From VCS, CSV and EML Files? The first line names the type

The first line names the type. ICS files start with BEGIN:VCALENDAR, contact cards with BEGIN:VCARD and emails with a header like From:. VCS files are the older format, and CSV and jCal files are other ways to list events.

Eight things get mixed up with ICS files because they all contain calendar items. The table lists what separates them. Every row ends with its source.

ICS, VCS, IFB, EML, CSV, VCF, jCal and archive files compared
Type What separates it
ICS file Starts with BEGIN:VCALENDAR and has VERSION:2.0. Defined in RFC 5545, with the type text/calendar. Source: IANA and our tests.
VCS file The older vCalendar format from the Versit Consortium, dated 18 September 1996. Its version is 1.0. Wikipedia says iCalendar is based on it. Source: Wikipedia and the Versit specification.
IFB file The same syntax for free or busy time. IANA registers the ending .ifb for it. Source: IANA.
EML invite An email with the calendar as a text/calendar part. The file starts with header lines like From:, and our script refuses it. Source: RFC 6047 and our tests.
CSV list A table of events with headers like Subject and Start Date. Google imports both ICS and CSV files. Source: Google and our tests.
Contact card Starts with BEGIN:VCARD. Three of our libraries opened one as a calendar, and our script refused it. Source: Our tests.
jCal file The JSON form of iCalendar, defined in RFC 7265. It starts with ["vcalendar". Source: RFC 7265 and our tests.
Calendar archive The .icbu file that Apple Calendar writes for all calendars. An ICS file stores one. Source: Apple.

Separate them with our script

Our script refuses any file that does not start with BEGIN:VCALENDAR, and it names the first line. For a contact card it prints BEGIN:VCARD, and for an email it prints the first header line. It never guesses.

Why the ending misleads

The FileInfo entry says two other kinds of file use .ics, IronCAD 3D scenes and Sony IC Recorder sound files. We also named 8 other files .ics, and the file command, our script and ics.py refused all 8.

A copy of one calendar read the same under 10 names. An ending is a label, and the first line says what an ICS file is.

Two files can store the same events in different ways. A VCS file has VERSION:1.0 and our script prints a warning for any version other than 2.0. The file ical4j_core.ics has that version, 81 events and the ending .ics, so the ending cannot separate the two.

Which one do you have

An email invite Read the EML file format page for messages with an invite inside.
An Outlook data file Read the PST file format page for mailboxes that store calendar items.
An Outlook for Mac archive Read the OLM file format page for the archive that Outlook for Mac writes.
A zip archive Read the ZIP file format page. Google says to extract a zip and import every ICS file on its own.

What Is the ICS File Format Made Of? The facts we could check, and where they came from

The IETF created the iCalendar format, and RFC 5545, IANA, Wikipedia and FileInfo document it. The facts below come from those sources and from our checks of 423 files and 50 damaged ICS files.

Facts about the ICS file format
Part What we could check
Maker The IETF. Wikipedia says it defined the format in 1998, based on vCalendar. RFC 2445 (November 1998) was written by Dawson of Lotus and Stenerson of Microsoft.
Name iCalendar. RFC 5545 (September 2009) replaced RFC 2445 and is titled Internet Calendaring and Scheduling Core Object Specification. Desruisseaux edited it.
First line BEGIN:VCALENDAR. IANA lists no magic number, so the first line is the only sign. 357 of our 423 files start with it.
Structure Lines that start with BEGIN and END form blocks. The parts are VEVENT, VTODO, VJOURNAL, VFREEBUSY, VTIMEZONE and VALARM, and our files have all six.
Lines A name, optional parameters, a colon and a value. CRLF ends every line, and lines of more than 75 bytes are folded with a space or tab. 217 of our 357 ICS files use LF only.
Text RFC 5545 says programs must write UTF-8 and must accept UTF-8 or ASCII. 36 of our ICS files have characters outside ASCII.
Required lines VERSION:2.0 and PRODID, once only. Events need UID and DTSTAMP, and every zone name needs a VTIMEZONE. 77 of our files have no VERSION and 91 have no PRODID.
Times Floating times, UTC times with a Z, local times with zone names and dates. 141 of our files use zone names, 89 use UTC, 70 use dates and 21 use floating times.
Endings .ics, and .ifb for free or busy time. IANA also lists the Mac type codes iCal and iFBf.
Later RFCs RFC 6868 (2013), 7529 (2015), 7808 (2016), 7953 (2016), 7986 (2016) and 9074 (2021) extend RFC 5545. 773 of our 2,469 time zone files use lines from RFC 7808 that two libraries refuse.
Our tests 423 files, 50 damaged copies, 2,469 time zone files, 10 renamed copies, 8 other files and 4 written files. Six readers and a 57 line script all worked on Linux.

About the values we list

Facts about the layout come from RFC 5545, Wikipedia and IANA, and every row names its source. The first line and the line rules were also checked against our ICS files. FileInfo is a directory, so we use it for the name and the other uses of the ending only.

Where a source and our tests disagree, we say so. RFC 5545 asks for CRLF and for lines of 75 bytes or less, and 217 of our 357 ICS files use LF only. All six readers opened the LF copy (D1). We do not know what a calendar app does with it.

What we left out

We opened no ICS file in Google Calendar, Outlook or Apple Calendar, and we tested no mail program. We tested no repair and no deletion, and we scanned no ICS file for malware. We tested no viewer from an outside page.

Our 423 files come from 7 public test folders, and 164 come from one project. Our damaged ICS files change one thing at a time in one ICS file. A reader that fails on our files can still work on your ICS file, and the reverse is true as well.

Sources checked

For the format, see the Wikipedia article on iCalendar, the full RFC 5545 text and the earlier RFC 2445 text. For the type and the endings, see the IANA entry for text/calendar.

For scheduling and time zones, see RFC 5546 and the RFC on time zone distribution. For the directory entry, see the FileInfo page on ICS files.

For importing, see the pages from Google, Microsoft and Apple. Every count came from the files and scripts in our research folder.

Frequently Asked Questions About ICS Files

What is an ICS file?

An ICS file is a calendar file in the iCalendar format. It is plain text and starts with a BEGIN line for the calendar. It stores events, tasks and time zones as lines of text. Of our 357 ICS files, 288 have events and 124 have time zones.

How do I open an ICS file?

Google Calendar, Outlook and Apple Calendar all have an import page for ICS files. We tested six other readers on 423 files instead. Our script opened 356 of 357 ICS files, the file command 349 and ical.js 318. We imported no file into a calendar app.

What does ICS stand for?

The format is called iCalendar, and RFC 5545 is titled Internet Calendaring and Scheduling Core Object Specification. IANA registers the ending .ics for the type text/calendar. The sources we read do not spell out the three letters.

Is an ICS file safe to open?

Reading an ICS file with a reader is safe, because an ICS file is text. We imported none into a calendar app and scanned none for malware. A name proves nothing, because a renamed calendar read the same under all 10 names. 24 of our files have an ATTACH line, so check where a link points before you follow it.

What is inside an ICS file?

An ICS file is lines of text that form blocks. Our example, base.ics, is 1,364 bytes and 52 lines long with a time zone, a weekly meeting and an all day event. Every line has a name, an optional parameter, a colon and a value, and long lines are folded.

Can I delete an ICS file?

We did not test deletion, and the sources we read give no deletion steps. Google and Microsoft both say an import copies the events and does not keep them in sync with the ICS file. Check whether the ICS file is a download or a subscription before you delete it, and write down its hash first.

How do I import an ICS file into my calendar?

Google says to open Settings and then Import and Export, and to select the ICS file. Microsoft says to select Add calendar and then Upload from file. Apple says to drag the ICS file into Calendar or to choose File and then Import. Apple warns that an import removes the custom colors of events. We tested none of these.

Why will my ICS file not open?

Eight causes cover what we found. The first four are a broken first line, a cut copy, a file that is not a calendar and a missing required line. The last four are broken values, line ends and folding, several calendars in one file and a strict reader. Read the first line of the ICS file first.

What is the difference between ICS and VCS?

A VCS file is the older vCalendar format from 1996, with version 1.0. An ICS file follows RFC 5545 and has version 2.0. Wikipedia says iCalendar is based on vCalendar. One of our files, ical4j_core.ics, has the ending .ics and version 1.0, so check the VERSION line.

How can I check if an ICS file is damaged?

Read the first line, then the entire file, then print the events with two readers. Six readers split on 170 of our 357 ICS files and on 27 of 50 damaged copies. Only 14 copies came back with the same events in all four libraries.

Can I rename a CSV or a text file to ICS?

No. A CSV list with the ending .ics is still a CSV list. The file command, our script and ics.py refused all 8 of our other files named .ics. Google imports CSV files on their own, with headers like Subject and Start Date, so import the CSV file instead.

How do I make an ICS file?

Write the lines with a library or export a calendar from an app. We tested icalendar, vobject, ics.py and ical.js, and all four wrote a meeting that all six readers opened. They wrote the time four ways, and only vobject defined the time zone. Apple says its Export command writes an ICS file.

Still Stuck With an ICS File? Seven routes out, depending on what went wrong

Your ICS file will not open

Read the first line and the entire file. The cause table lists what to try in order.

You need to write or move events

The convert part shows four writers and what every writer did with the time zone.

Is it an email? The page on EML files covers messages with an invite as a calendar part.

Is it a mailbox? The page on PST files covers the Outlook data file that stores calendar items.

Is it a zip? The page on ZIP files covers archives. Google says to extract a zip and import every ICS file on its own.

Is it a file type you do not know? Browse the file extension resource library, or send it on the submit a file type page.

Do you need the format facts? Read the format part for the structure, the lines and the sources of ICS files.