I think this is a really interesting subject, so I don't want to dissuade others from replying. But there was a great discussion of this question a little over a half a year ago. The short answer was, portions of the Magna Carta are still in effect, including Clause 29, the origin of habeas corpus doctrine. At a little over 700 years old, that comes close, but someone else also pointed to an 800-year old Scottish law.
It is likely the oldest legal document/treaty still in effect is connected to a very old monastery that is still existing. There are quite a few ones in Europe. They still own land which has been donated to them in the 8th/9th/10th century. But it is a bit tiresome to look up an existing monastery with a document about the donation of a piece of land that was never traded away through the centuries.
However, St. Catherine's Monastery on Mount Sinai was established in the 6th century. Much to my surprise / TIL there is a legal document surviving in copies, that was issued by prophet Mohammed granting the monastery (or Christians in a more general sense) protection and other privileges: The Ashtiname of Muhammad
It was issued in AD 626 or around it. Given the fact the monastery in this islamic region still exists today proofs the protection it received (and still receives) and makes it safe to conclude the document is still in effect today.
There are probably older legal documents still in effect, but this one seems to put away with the Magna Carta and the Fairs Act fairly easily.
EDIT: Layout and typo
There is the Fairs Act that predates the Magna Carta.