A typical 5G Ultra-Dense Network (UDN) comprises different types of Base Stations (BSs) in its structure. Dense deployment of small-cell BSs within a macrocell BS's coverage offers significant benefits, as the distance between a User Equipment (UE) and its small-cell BS is shorter with robust signals. Thus, the network capacity will increase dramatically. However, selecting an appropriate small-cell BS for a particular UE becomes a challenge in 5G UDNs. This study proposed a mechanism to address the cell selection problem and maximize fairness among UEs when making the cell selection decision. The proposed mechanism considered different parameters. The load balance for each small-cell BS was considered to fairly distribute UEs and avoid traffic congestion. Moreover, the signal strength was considered with the achievable data rate for all small-cell BSs to stimulate idle small-cell BSs to be in operating mode. A simulation was carried out in MATLAB to evaluate the proposed mechanism. Signal-to-Interference-Ratio (SINR) and Signal Strength (SS) -based strategies were also simulated for comparison. The proposed solution outperformed the other schemes in terms of fairness, as the UEs attached to the system were fairly distributed among small-cell BSs. Furthermore, the proposed mechanism achieved the best radio resource distribution in terms of fairness compared to the two other schemes.