Several tech companies, including Google parent Alphabet Inc., Facebook Inc. and Microsoft Corp., plan to file a joint motion supporting Apple Inc. in its court fight against the Justice Department over unlocking an alleged terrorist’s iPhone, according to people familiar with the companies’ plans.

At least one other tech company plans to be included in a joint amicus brief next week generally supporting Apple’s position that unlocking the iPhone would undermine tech firms’ efforts to protect their users’ digital security,...