Midnight marks the beginning and ending of each day in civil time throughout the world. It is the dividing point between one day and another.

When someone refers to "midnight tonight" or "midnight last night" the reference of time is obvious. However, if a date/time is referred to as "at midnight on Friday, October 20th" the intention could be either midnight the beginning of the day or midnight at the end of the day.

To avoid ambiguity, specification of an event as occurring on a particular day at 11:59 p.m. or 12:01 a.m. is a good idea, especially legal documents such as contracts and insurance policies.

Another option would be to use 24-hour clock, using the designation of 00:00 to refer to Midnight aa the beginning of a given day (or date) and 24:00 to designate the end of a given day (or date).

More Information#

There might be more information for this subject on one of the following:
[#1] http://www.nist.gov/pml/div688/times.cfm