Half of the waste some 2,000 tons will be sent back to Germany by the end of August, the Environmental Ministry said in a statement.
Wednesday's shipment was destined for a waste incinerator in Premnitz, west of Berlin.
Last year, Hungarian officials discovered that 4,100 tons of garbage was illegally dumped in southern Hungary and suspected a foreign company. Investigators traced the waste to a business in Germany.
Hungarian firms involved in the illegal dumping have been fined 70 million forints (US$380,000, EUR282,000).
About 3,200 tons of the garbage is said to be from the state of Baden-Wuerttemberg, the rest from neighboring Bavaria, the ministry said.
Baden-Wuerttemberg had so far agreed to pay an estimated EUR400,000 (US$537,000) for the return of 1,800 tons of its garbage, the state news agency MTI said.
It was unclear who would pay for the rest of the return shipments, the ministry said, adding that it planned to tighten laws that allow the import of foreign waste.
Hungary and Germany are European Union members, and there are no inspections at border crossings within the EU.