diff --git a/eth/api_tracer.go b/eth/api_tracer.go
index 2800ff659c774d69efef9f8d6c9490a3318b3dcf..ce211cbd99ef8d4eebd8fdc48d5b76eabfb2da2b 100644
--- a/eth/api_tracer.go
+++ b/eth/api_tracer.go
@@ -795,6 +795,11 @@ func (api *PrivateDebugAPI) computeTxEnv(blockHash common.Hash, txIndex int, ree
 	if err != nil {
 		return nil, vm.Context{}, nil, err
 	}
+
+	if txIndex == 0 && len(block.Transactions()) == 0 {
+		return nil, vm.Context{}, statedb, nil
+	}
+
 	// Recompute transactions up to the target index.
 	signer := types.MakeSigner(api.eth.blockchain.Config(), block.Number())