I am getting this error when i try to add 9.6 slave to 9.4 master.
< 2017-10-09 22:56:31.081 UTC > FATAL: database files are incompatible with server < 2017-10-09 22:56:31.081 UTC > DETAIL: The data directory was initialized by PostgreSQL version 9.4, which is not compatible with this version 9.6.1.
Ram
No, you cannot do that with physical streaming replication. They must be the same major version number. 9.5 -> 9.5.