This paper presents a data-driven two-stage distributionally robust planning tool for sustainable microgrids under the uncertainty of load and power generation of renewable energy sources (RES) during the planning horizon. In the proposed two-stage planning tool, the first-stage investment variables are considered as here-and-now decisions and the second-stage operation variables are considered as wait-and-see decisions. In practice, it is hard to obtain the true probability distribution of the uncertain parameters. Therefore, a Wasserstein metric-based ambiguity set is presented in this paper to characterize the uncertainty of load and power generation of RES without any presumption on their true probability distributions. In the proposed data-driven ambiguity set, the empirical distributions of historical load and power generation of RES are considered as the center of the Wasserstein ball. Since the proposed distributionally robust planning tool is intractable and it cannot be solved directly, duality theory is used to come up with a tractable mixed-integer linear (MILP) counterpart. The proposed model is tested on a 33-bus distribution network and its effectiveness is showcased under different conditions.