Halide double perovskite Cs2BMX6 possesses excellent photoelectronic properties. The material properties would have been markedly influenced by the variant electronic structures if the chemical elements of B, M and X had been changed. In this paper, we have a systematic investigation on the mechanical, electronic structure and optical properties of Cs2BSbBr6 (B=Li, Na, K, Rb) using first-principles method. The results show that Cs2LiSbBr6 and Cs2NaSbBr6 are indirect band gap semiconductors, while Cs2KSbBr6 and Cs2RbSbBr6 are direct band gap semiconductors. The band gap values of Cs2BSbBr6 (B = Li, Na, K, Rb) are 2.81, 2.96, 3.37 and 3.36eV, respectively. It is worth noting that the band gap value of Cs2BSbBr6 increases with the increased atomic number of B (Li-Na-K-Rb) atoms. Due to the inter-band transition of electrons, the strong absorption spectrum occurs in the visible region. These physical and electronic properties of Cs2BSbBr6 provide references for the potential applications.