The purpose of this article is to analyze the impact of network coding in wireless networks. We consider a network coded ALOHA that performs bi-directional network coding over the ALOHA MAC protocol in a star topology network. The transmission probabilities of each outer node and the center node, and the target signal-to-interference-plusnoise ratio (SINR) are jointly optimized to achieve the maximum throughput of coded ALOHA. We analyze and compare the optimal performance of slotted and coded ALOHA. Under the unsaturated traffic condition at the center node, we derive practical throughput and delay, considering the network coding opportunity and the maximum queue length of the center node. Under the saturated traffic condition, we obtain a throughput upper bound of coded ALOHA to judge the ideal gain of network coding. The impact of asymmetric topology is evaluated with simulations.