A two-dimensional lattice Boltzmann method (LBM) based model is developed for the modelling of dendritic growth during alloy solidification in the presence of forced and natural convections. Instead of conventional continuum-based Navier-Stokes solvers,the present model adopts a kinetic-based LBM for the numerical computations of transport phenomena during solidification. Three sets of distribution functions are employed to constitute the LBM evolution equations for numerically calculating fluid flow as well as solutal and thermal transports which are controlled by both diffusion and convection. By solving the LBM evolution equations, the local temperature and the composition at the solid/liquid interface can be obtained. The kinetics of dendritic growth is then investigated based on a solutal equilibrium approach proposed by Zhu and Stefanescu. The model is verified by the comparison between the simulations and theoretical predictions. The simulated upstream tip velocities and radii of the dendrite growing in a melt with natural convections are found to be in reasonabl agreement with the predictions from the modified Lipton-Glicksman-Kurz model that takes into account the effects of convection. For the convective dendritic growth in a forced flow, the simulated growth Pclet number of the upstream tip as a function of the flow Pclet number is very close to the Oseen-Ivantsov solution. It is also found that convection transports heat and solute from the upstream region to the downstream region, producing asymmetrical dendrite that grows faster in the upstream direction, whereas slower in the downstream direction.