g-C3N4/WTe2 heterostructure with tunable vdW gap shows a favorable solar energy conversion performance.