A method for automatic parking, the method comprising: determining node distribution information for a to-be-parked area during the automatic parking, wherein the node distribution information comprises a plurality of nodes through which a vehicle is capable of passing; and determining an intermediate node based on the node distribution information, and obtaining a plurality of neighboring nodes by searching for neighboring nodes based on the intermediate node, characterized in that the method further comprises: determining cost information of candidate routes corresponding to the plurality of neighboring nodes respectively, wherein the candidate routes are each a route from a starting node to the intermediate node via a neighboring node; and determining a target neighboring node based on the cost information, and performing the automatic parking in accordance with the target neighboring node, wherein said determining the cost information of candidate routes corresponding to the plurality of neighboring nodes respectively comprises: determining, for one of the candidate routes corresponding to each of the plurality of neighboring nodes, route attribute information comprising a route length, an obstacle distance, and the number of times of steering of the vehicle; and determining the cost information based on the route attribute information. determining node distribution information for a to-be-parked area during the automatic parking, wherein the node distribution information comprises a plurality of nodes through which a vehicle is capable of passing; and determining an intermediate node based on the node distribution information, and obtaining a plurality of neighboring nodes by searching for neighboring nodes based on the intermediate node, characterized in that the method further comprises: determining cost information of candidate routes corresponding to the plurality of neighboring nodes respectively, wherein the candidate routes are each a route from a starting node to the intermediate node via a neighboring node; and determining a target neighboring node based on the cost information, and performing the automatic parking in accordance with the target neighboring node, wherein said determining the cost information of candidate routes corresponding to the plurality of neighboring nodes respectively comprises: determining, for one of the candidate routes corresponding to each of the plurality of neighboring nodes, route attribute information comprising a route length, an obstacle distance, and the number of times of steering of the vehicle; and determining the cost information based on the route attribute information. determining cost information of candidate routes corresponding to the plurality of neighboring nodes respectively, wherein the candidate routes are each a route from a starting node to the intermediate node via a neighboring node; and determining a target neighboring node based on the cost information, and performing the automatic parking in accordance with the target neighboring node, wherein said determining the cost information of candidate routes corresponding to the plurality of neighboring nodes respectively comprises: determining, for one of the candidate routes corresponding to each of the plurality of neighboring nodes, route attribute information comprising a route length, an obstacle distance, and the number of times of steering of the vehicle; and determining the cost information based on the route attribute information. determining, for one of the candidate routes corresponding to each of the plurality of neighboring nodes, route attribute information comprising a route length, an obstacle distance, and the number of times of steering of the vehicle; and determining the cost information based on the route attribute information.