Finite element numerical simulations were carried out in 2D geometries to map the magnetic field and force distribution produced by rectangular permanent magnets as a function of their size and position with respect to a microchannel. A single magnet, two magnets placed in attraction and in repulsion have been considered. The goal of this work is to show where magnetic beads are preferentially captured in a microchannel. These simulations were qualitatively corroborated, in one geometrical case, by microscopic visualizations of magnetic bead plug formation in a capillary. The results show that the number of plugs is configuration dependent with: in attraction, one plug in the middle of the magnets; in repulsion, two plugs near the edges of the magnets; and with a single magnet, a plug close to the center of the magnet. The geometry of the magnets (h and l are the height and length of the magnets respectively) and their relative spacing s has a significant impact on the magnetic flux density. Its value inside a magnet increases with the h/l ratio. Consequently, bar magnets produce larger and more uniform values than flat magnets. The l/s ratio also influences the magnetic force value in the microchannel, both increasing concomitantly for all the configurations. In addition, a zero force zone in the middle appears in the attraction configuration as the l/s ratio increases, while with a single magnet, the number of maxima and minima goes from one to two, producing two focusing zones instead of only one.