Easy approach: Link2SD
If you are sure that the file attributes does not matter, then there's an acceptable way to do this. Root is required.
1. Copy the app data from
/data/data/com.example.foo to somewhere in your SD card. Personally I recommend
sdcard/Android/data/com.example.foo. If you are running Android Lollipop or up, there will be a symbolic link named
lib, leave it alone.
2. Kill the app process. Remove the original data. Open a terminal emulator (or adb). Run
ln -s /sdcard/Android/data/com.example.foo/files /data/data/com.example.foo/files
That's all. To revert this job, it's a little complex. You'll have to
chown the proper file modes and attributes manually after copying them back.
Never copy and link the
/data/data/com.example.foo folder directly as the symbolic link
lib inside will fail, which will lead to unknown behavior. Link every (or some of them at your choice) subfolders one by one.