Co4Ta2O9 exhibits a three-dimensional magnetic lattice based on the buckled honeycomb motif. It shows unusual magnetoelectric effects, including the sign change and non-linearity. These effects cannot be understood without the detailed knowledge of the magnetic structure. Herein, we report neutron diffraction and direction-dependent magnetic susceptibility measurements on Co4Ta2O9 single crystals. Below 20.3 K, we find a long-range antiferromagnetic order in the alternating buckled and flat honeycomb layers of Co2+ ions stacked along the c axis. Within experimental accuracy, the magnetic moments lie in the ab plane. They form a canted antiferromagnetic structure with a tilt angle of ~ 14 degrees at 15 K in the buckled layers, while the magnetic moments in each flat layer are collinear. This is directly evidenced by a finite (0, 0, 3) magnetic Bragg peak intensity, which would be absent in the collinear magnetic order. The magnetic space group is C2/c. It is different from the previously reported C2/c group, also found in the isostructural Co4Nb2O9. The revised magnetic structure successfully explains the major features of the magnetoelectric tensor of Co4Ta2O9 within the framework of the spin-flop model.