(CNN)On June 19, 1865, Union Army Maj. Gen. Gordon Granger rode into Galveston, Texas, and announced that the more than 250,000 enslaved Black people in the state were free by executive decree.
The National Archives has unearthed the original handwritten Juneteenth order
That decree was General Order No. 3, and is the basis for what's now known as Juneteenth -- the oldest celebration of the end of slavery in the United States.
The National Archives announced on Friday that it has unearthed the original handwritten order issued by Granger 155 years ago, just in time for this year's holiday. The order, written in embellished penmanship, was contained in a bound volume that begins on one page and continues onto another.
"The people of Texas are informed that, in accordance with a proclamation from the Executive of the United States, all slaves are free," the order reads.
"This involves an absolute equality of personal rights and rights of property between former masters and slaves and the connection heretofore existing between them becomes that between employer and hired labor."
The National Archives told CNN in an email that one of its staff writers, Michael Davis, had been working on a story about Juneteenth this week. Davis contacted Trevor Plante, director of the archive's textual records division, to see if the original order was part of the National Archives' holdings.
Plante located General Order No. 3 in a formal order book for the district of Texas, and brought it out on June 18 for the writer's story.
The order was in "very good condition," according to a statement from the archive's public communications office.
"The National Archives safeguards many of the nation's most important records related to African American history and civil rights, and General Order Number 3 is one of those records," Archivist of the United States David S. Ferriero said in a statement.
"We know from history that certain events took place, and it's always a delight when we can help make history come alive by sharing the actual documentation of those events."
Printed versions of the order were published in the 1890s in a US government publication titled, "War of the Rebellion: A Compilation of the Official Records of the Union and Confederate Armies volumes."
But the handwritten order had not been digitized or found online, despite being a part of the archives' holdings, according to the statement from the archive's public communications office.
"It may or may not have been seen by researchers in the past," according to the statement.
The Emancipation Proclamation, issued by President Abraham Lincoln in 1863, legally declared all enslaved people in Confederate states free.
But African Americans remained enslaved in areas that were still under Confederate control, according to the National Museum of African American History and Culture. In Texas, emancipation for enslaved people came two years later, when about 2,000 Union troops rode into Galveston and issued Granger's order.
Though General Order No. 3 was key to freeing enslaved people in Texas, the language in it was far from perfect.
"The freedmen are advised to remain quietly at their present homes, and work for wages," part of the order reads. "They are informed that they will not be allowed to collect at military posts and that they will not be supported in idleness either there or elsewhere."
It was a sign that freedom and equal rights for Black people in the United States would be an uphill battle.