This dissertation encompasses three different topics on international trade and migration. The first chapter is the introduction. The second chapter investigates the short run effects of regional trade agreements on trade costs. It is widely accepted that the reinforcement of Regional Trade Agreements (RTAs) aiming at trade costs reduction among trade partners requires time. This paper investigates the effects of RTAs on trade costs over time by using unique micro-price data. As a key factor compared to the literature, excluding the local distribution costs, the trade costs we calculated are based on the arbitrage condition to equalize traded input prices across international cities. We confirm that having an RTA on average lowers trade costs significantly. Furthermore, data shows significant and negative effects of RTAs on trade costs over time. Specifically, besides the initial impact on trade costs, having an RTA continuously lower trade costs every year after the commencement of the RTA. Gravity variables such as distance, common language, colonial ties, free trade agreements, and adjacency are used to capture the effects of trade costs in empirical studies. The third chapter decomposes the overall effects of gravity variables on trade through three gravity channels: duties/tariffs (DC), transportation-costs (TC), and dyadic-preferences (PC). When PC is ignored as is typical in the literature, it is shown that nearly all gravity effects are trough distance; 29 percent vi through DC and 71 percent through TC. However, the additional channel of PC is introduced and shown to dominate other channels, with adjacency contributing about 45 percent, distance about 32 percent, colonial ties about 14 percent, free trade agreements about 7 percent, and common language about 2 percent. These results imply that gravity variables mainly capture the effects of demand shifters rather than supply shifters (as implied by the existing literature). The results are further connected to several existing discussions in the literature, such as welfare gains from trade and the distance puzzle. The fourth chapter utilizes an immigration inflow data set from OECD countries during the period of 1984 to 2015 to shed lights on how institutional quality affects the immigration rate. With the analysis in the fixed-effects framework, we construct a set of country-time specific institutional quality indexes to examine their effects on the immigration rate. The paper shows that other than the network effects, GDP difference, and migration costs, institutional qualities in both destination and source countries matter when it comes to potential migration decisions. Specifically, better socioeconomic conditions in the destination countries, and worse foreign debt, budget balance, government stability, internal conflicts, and corruption conditions in the source countries increase the immigration inflow. vii