The 23 year old Lafayette had been sent by General Washington to Virginia in search of Benedict Arnold. This happened at about the same time that Cornwallis crossed into Virginia. Lafayette, although out numbered, would follow Cornwallis throughout the area, always sending intelligence reports back to Washington informing him of Cornwallis' position. In time, it became evident that Cornwallis had stopped his Virginia raids and was setting up a major defensive position at Yorktown. At that time, Lafayette moved his men back to nearby Williamsburg and kept a watchful eye on Cornwallis as they built their defensive earthworks around the small town.
Washington sent word to Lafayette if possible, keep Cornwallis in Yorktown. The French navy along with more supplies were almost ready to set sail for the Chesapeake Bay. In Washington's plans, it would be a combined attack (Lafayette, DeGrasse, and Washington) in early September.
It was decided that Washington and the allied armies would leave New York on August 21, and do so without alerting Clinton in New York City that they were leaving. Great effort went into keeping up appearances; even the troops did not know the full extent of the plan. A new camp was established just south of the city, in New Jersey, where it would appear to Clinton that the Americans were preparing to attack Staten Island. Secrecy was a vital ingredient in the recipe.
Clinton had about 17,000 troops in and around New York. This was a sizeable force and if Washington's move south was discovered too soon, it could have a disastrous result. Besides the small force maintaining the appearance of a permanent encampment in New Jersey, there was also some 2500 troops along the highlands of the Hudson River. All of these forces were supposedly protected by Washington's army and would be safe from attack by Clinton. Should Clinton uncover the fact that Washington's main forces had left the area, it would put these forces in grave jeopardy. In fact, the ruse had kept Clinton in the dark and it wasn't until September 2 that Clinton learned of Washington's departure some 2 weeks before. By this time, the New Jersey encampment had already been abandoned by the Americans.
All was not well with the American forces however. They were not happy about marching south, away from their homes and farms in the north. They had not been paid, they had no recognizable uniforms anymore. When the group arrived in Philadelphia, Washington pleaded for at least a month's pay to give his men. This was done by borrowing money from Rochambeau's military chest. It helped ease the men's concerns, at least for a while.
On September 4, Washington received word from a runner that French frigates had arrived in the Chesapeake and were ready to have the troops board transports. By September 18 the allies had all embarked from Baltimore and Annapolis on their way south to the James River not far from Williamsburg. All of the men were put ashore by September 26.
Meanwhile, Lafayette had split his forces into 2 divisions to keep Cornwallis in place. His troops took position near Williamsburg and General Wayne had taken position at Cabin Point on the south side of the James River, south of Williamsburg. Cornwallis was aware of these maneuvers. He hastened completion of his outer defensive earthworks and the clearing of the woods in front of them. He wanted a clear line of fire against the colonials if they dared to approach his position.
Earlier DeGrass had positioned some 24 ships of the line outside Hampton Roads on August 30. When the British fleet arrived on September 5, the French navy had control of the mouth of the Chesapeake, preventing them from reinforcing the Cornwallis at Yorktown. There was a small action between the two navies that lasted about 2 hours, it ended with the British fleet withdrawing and finally returning to New York a couple of days later. The noose was being tightened around Cornwallis.
On September 10, the heavy French artillery from Newport arrived on the Chesapeake and was unloaded on the James River side of the penninsula. Once the artillery was hauled overland to the newly constructed siege lines surrounding Yorktown, everything would be in place for the final assault on Cornwallis.