Dimension of an obstacle placed in a hot water tank for thermal stratification is optimized numerically. Numerical method is validated using both experimental and numerical results. A cylindrical tank used to store heat for solar collector applications is considered. A cylindrical obstacle with a hole in the middle is placed in the tank and various f/H and g/D ratios of the obstacle geometry are considered. Here H and D are the height and diameter of the tank, respectively, where f is the distance from the bottom surface of the tank to the cold-water inlet channel and g is the diameter of the hole in the obstacle. Temperature distribution in the tank, water temperature supplied by the tank, and temperature differences at various tank inlet and outlets are obtained for various f/H and g/D ratios. The results show that placing obstacle in the tank improves thermal stratification, and thus it increases the temperature of water supplied by the tank compared with no obstacle case and that the best thermal stratification is obtained for obstacle dimensions corresponding to g/D ratio of 0.2 and f/H ratio of 0.13.