This paper studies and formulates the problem of distributed filtering with a diffusion strategy for state estimation of a dynamic system by using observations from sensors in a network. The sensor-nodes have estimation ability and work in a collaborative manner. The information transmission across the network abides by the diffusion strategy that each node communicates only with its neighbors. First, we propose a cost function for a trade-off between accuracy and consensus. Then, we derive our algorithm based on this cost and analyze its mean-square performance. Illustrative numerical examples are provided to verify the good performance of our method.